Class ClientHandler
java.lang.Object
com.j_spaces.kernel.ManagedRunnable
com.gigaspaces.lrmi.nio.selector.handler.AbstractSelectorThread
com.gigaspaces.lrmi.nio.selector.handler.client.ClientHandler
- All Implemented Interfaces:
Runnable
A client side selector thread that handles Async remote calls. the handler works against a
context to support both read and write actions. all channel activities are non blocking.
- Since:
- 6.5
- Author:
- asy ronen
-
Field Summary
Fields inherited from class AbstractSelectorThread
_logger, ownerThread -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidaddChannel(SocketChannel channelSocket, Context ctx) protected voidcancelKey(SelectionKey key) protected voidprotected voidvoidremoveChannel(SocketChannel channelSocket, Context ctx) voidsetReadInterest(Context ctx) voidsetWriteInterest(Context ctx) voidshutdown()Methods inherited from class AbstractSelectorThread
closeChannel, getSelector, register, run, waitWhileFinishMethods inherited from class ManagedRunnable
requestShutdown, shouldShutdown
-
Constructor Details
-
ClientHandler
- Throws:
IOException
-
-
Method Details
-
enableSelectionKeys
protected void enableSelectionKeys()- Specified by:
enableSelectionKeysin classAbstractSelectorThread
-
handleConnection
- Specified by:
handleConnectionin classAbstractSelectorThread- Throws:
IOExceptionInterruptedException
-
addChannel
-
removeChannel
-
setReadInterest
-
setWriteInterest
-
cancelKey
- Overrides:
cancelKeyin classAbstractSelectorThread
-
shutdown
public void shutdown()
-