public abstract class AbstractClientSelectionHandler extends Object implements SelectionHandler, Runnable
Modifier and Type | Field and Description |
---|---|
protected ClientConnection |
connection |
protected ClientConnectionManager |
connectionManager |
protected SwCounter |
eventCount |
protected ILogger |
logger |
protected SocketChannelWrapper |
socketChannel |
Constructor and Description |
---|
AbstractClientSelectionHandler(ClientConnection connection,
NonBlockingIOThread ioThread,
LoggingService loggingService) |
Modifier and Type | Method and Description |
---|---|
void |
onFailure(Throwable e)
Is called when the
SelectionHandler.handle() throws an exception. |
void |
register() |
protected void |
shutdown() |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
handle
protected final ILogger logger
protected final SocketChannelWrapper socketChannel
protected final ClientConnection connection
protected final ClientConnectionManager connectionManager
protected final SwCounter eventCount
public AbstractClientSelectionHandler(ClientConnection connection, NonBlockingIOThread ioThread, LoggingService loggingService)
protected void shutdown()
public final void onFailure(Throwable e)
SelectionHandler
SelectionHandler.handle()
throws an exception.
The idiom to use a handler is:
try{
handler.handle();
} catch(Throwable t) {
handler.onFailure(t);
}
onFailure
in interface SelectionHandler
public void register()
Copyright © 2016 Hazelcast, Inc.. All Rights Reserved.