|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||

public interface IIoHandlerCallback
Call back interface to notify io events of the IIoHandler. The IIoHandler
is responsible to notify the events in the occured order.
This class is experimental and is subject to change
| Method Summary | |
|---|---|
void |
onConnect()
notifies that the underlying connection has been established. |
void |
onConnectionAbnormalTerminated()
notifies that the connection has to be closed (connection is corrupt, selector has be closed, ...). |
void |
onConnectionTimeout()
notifies the connection time out has been occured. |
void |
onDataRead()
notifies that data has been read from the socket. |
void |
onDisconnect()
notifies that the underlying connection has been disconnected (closed). |
void |
onIdleTimeout()
notifies the idle time out has been occured. |
void |
onWriteException(java.io.IOException ioException)
notifies that an error has been occured by writing data on the socket. |
void |
onWritten()
notifies that data has been written on the socket. |
| Method Detail |
|---|
void onDataRead()
IIoHandlerContext.getWorkerpool() is not null.
If the IIoHandlerContext.getWorkerpool() is null,
no dedicate worker threads will be used (non-multithreading mode). IIoHandlerContext.isAppHandlerListenForDataEvent()
method returns true. If the handler requires synchronization (IIoHandlerContext#getAppHandlerSynchronizationMode() != Synchronized.Mode#OFF),
the callback method has to be called in a synchronized context.
void onConnect()
IIoHandlerContext.isAppHandlerListenForConnectEvent()
method returns true. If the handler is not thread-safe (IIoHandlerContext.isAppHandlerThreadSafe() is false),
the callback method has to be called in a synchronized context.onDataRead()
void onDisconnect()
IIoHandlerContext.isAppHandlerListenforDisconnectEvent()
method returns true. If the handler is not thread-safe (IIoHandlerContext.isAppHandlerThreadSafe() is false),
the callback method has to be called in a synchronized context.onDataRead()
void onIdleTimeout()
IIoHandlerContext.isAppHandlerListenForTimeoutEvent()
method returns true. If the handler is not thread-safe (IIoHandlerContext.isAppHandlerThreadSafe() is false),
the callback method has to be called in a synchronized context.onDataRead()
void onConnectionTimeout()
IIoHandlerContext.isAppHandlerListenForTimeoutEvent()
method returns true. If the handler is not thread-safe (IIoHandlerContext.isAppHandlerThreadSafe() is false),
the callback method has to be called in a synchronized context.onDataRead()
void onConnectionAbnormalTerminated()
onDataRead()
void onWritten()
void onWriteException(java.io.IOException ioException)
ioe - ioException an io exception
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||