org.glassfish.grizzly.nio
Class DefaultSelectionKeyHandler

java.lang.Object
  extended by org.glassfish.grizzly.nio.DefaultSelectionKeyHandler
All Implemented Interfaces:
SelectionKeyHandler

public final class DefaultSelectionKeyHandler
extends Object
implements SelectionKeyHandler

Author:
oleksiys

Field Summary
 
Fields inherited from interface org.glassfish.grizzly.nio.SelectionKeyHandler
DEFAULT_SELECTION_KEY_HANDLER
 
Constructor Summary
DefaultSelectionKeyHandler()
           
 
Method Summary
 void cancel(SelectionKey key)
           
 NIOConnection getConnectionForKey(SelectionKey selectionKey)
           
 IOEvent[] getIOEvents(int interest)
           
 int ioEvent2SelectionKeyInterest(IOEvent ioEvent)
           
 void onKeyDeregistered(SelectionKey key)
           
 void onKeyRegistered(SelectionKey key)
           
 boolean onProcessInterest(SelectionKey key, int interest)
           
 IOEvent selectionKeyInterest2IoEvent(int selectionKeyInterest)
           
 void setConnectionForKey(NIOConnection connection, SelectionKey selectionKey)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DefaultSelectionKeyHandler

public DefaultSelectionKeyHandler()
Method Detail

onKeyRegistered

public void onKeyRegistered(SelectionKey key)
Specified by:
onKeyRegistered in interface SelectionKeyHandler

onKeyDeregistered

public void onKeyDeregistered(SelectionKey key)
Specified by:
onKeyDeregistered in interface SelectionKeyHandler

cancel

public void cancel(SelectionKey key)
            throws IOException
Specified by:
cancel in interface SelectionKeyHandler
Throws:
IOException

ioEvent2SelectionKeyInterest

public int ioEvent2SelectionKeyInterest(IOEvent ioEvent)
Specified by:
ioEvent2SelectionKeyInterest in interface SelectionKeyHandler

getIOEvents

public IOEvent[] getIOEvents(int interest)
Specified by:
getIOEvents in interface SelectionKeyHandler

selectionKeyInterest2IoEvent

public IOEvent selectionKeyInterest2IoEvent(int selectionKeyInterest)
Specified by:
selectionKeyInterest2IoEvent in interface SelectionKeyHandler

onProcessInterest

public boolean onProcessInterest(SelectionKey key,
                                 int interest)
                          throws IOException
Specified by:
onProcessInterest in interface SelectionKeyHandler
Throws:
IOException

getConnectionForKey

public NIOConnection getConnectionForKey(SelectionKey selectionKey)
Specified by:
getConnectionForKey in interface SelectionKeyHandler

setConnectionForKey

public void setConnectionForKey(NIOConnection connection,
                                SelectionKey selectionKey)
Specified by:
setConnectionForKey in interface SelectionKeyHandler


Copyright © 2012 Oracle Corporation. All Rights Reserved.