com.sun.grizzly.nio.transport
Class UDPNIOStreamTransportFilter

java.lang.Object
  extended by com.sun.grizzly.filterchain.FilterAdapter
      extended by com.sun.grizzly.nio.transport.UDPNIOStreamTransportFilter
All Implemented Interfaces:
Filter

public class UDPNIOStreamTransportFilter
extends FilterAdapter

The UDPNIOTransport's transport Filter implementation

Author:
Alexey Stashok

Field Summary
static int DEFAULT_BUFFER_SIZE
           
 
Method Summary
 void exceptionOccurred(FilterChainContext ctx, Throwable error)
          Notification about exception, occured on the FilterChain
 NextAction handleRead(FilterChainContext ctx, NextAction nextAction)
          Execute a unit of processing work to be performed, when channel will become available for reading.
 NextAction handleWrite(FilterChainContext ctx, NextAction nextAction)
          Execute a unit of processing work to be performed, when channel will become available for writing.
 
Methods inherited from class com.sun.grizzly.filterchain.FilterAdapter
getFilterChain, getIndex, handleAccept, handleClose, handleConnect, isIndexable, postAccept, postClose, postConnect, postRead, postWrite, setIndex
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

DEFAULT_BUFFER_SIZE

public static final int DEFAULT_BUFFER_SIZE
See Also:
Constant Field Values
Method Detail

handleRead

public NextAction handleRead(FilterChainContext ctx,
                             NextAction nextAction)
                      throws IOException
Description copied from class: FilterAdapter
Execute a unit of processing work to be performed, when channel will become available for reading. This Filter may either complete the required processing and return false, or delegate remaining processing to the next Filter in a FilterChain containing this Filter by returning true.

Specified by:
handleRead in interface Filter
Overrides:
handleRead in class FilterAdapter
Parameters:
ctx - FilterChainContext
nextAction - default NextAction, which Filter could change in order to control how FilterChain will continue the execution
Returns:
NextAction instruction for FilterChain, how it should continue the execution
Throws:
IOException

handleWrite

public NextAction handleWrite(FilterChainContext ctx,
                              NextAction nextAction)
                       throws IOException
Description copied from class: FilterAdapter
Execute a unit of processing work to be performed, when channel will become available for writing. This Filter may either complete the required processing and return false, or delegate remaining processing to the next Filter in a FilterChain containing this Filter by returning true.

Specified by:
handleWrite in interface Filter
Overrides:
handleWrite in class FilterAdapter
Parameters:
ctx - FilterChainContext
nextAction - default NextAction, which Filter could change in order to control how FilterChain will continue the execution
Returns:
NextAction instruction for FilterChain, how it should continue the execution
Throws:
IOException

exceptionOccurred

public void exceptionOccurred(FilterChainContext ctx,
                              Throwable error)
Description copied from class: FilterAdapter
Notification about exception, occured on the FilterChain

Specified by:
exceptionOccurred in interface Filter
Overrides:
exceptionOccurred in class FilterAdapter
Parameters:
ctx - event processing FilterChainContext
error - error, which occurred during FilterChain execution


Copyright © 2009 SUN Microsystems. All Rights Reserved.