|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface SingleSessionIoHandler
A session handler without an IoSession parameter for simplicity.
A SingleSessionIoHandler is similar to an IoHandler with
the notable difference that a SingleSessionIoHandler is used only
by one session at a time. Thus, there is no IoSession parameter in
the methods of this interface.
Because events are passed to the session in order, it is possible to store conversational state as instance variables in this object.
| Method Summary | |
|---|---|
void |
exceptionCaught(Throwable cause)
Invoked when any exception is thrown by user IoHandler
implementation or by MINA. |
void |
messageReceived(Object message)
Invoked when protocol message is received. |
void |
messageSent(Object message)
Invoked when protocol message that user requested by IoSession.write(Object) is sent out actually. |
void |
sessionClosed()
Invoked when the connection is closed. |
void |
sessionCreated()
Invoked when the session is created. |
void |
sessionIdle(IdleStatus status)
Invoked when the connection is idle. |
void |
sessionOpened()
Invoked when the connection is opened. |
| Method Detail |
|---|
void sessionCreated()
throws Exception
ExceptionIoHandler.sessionCreated(IoSession)
void sessionOpened()
throws Exception
ExceptionIoHandler.sessionOpened(IoSession)
void sessionClosed()
throws Exception
ExceptionIoHandler.sessionClosed(IoSession)
void sessionIdle(IdleStatus status)
throws Exception
IdleStatus. This
method is not invoked if the transport type is UDP.
status - the type of idleness
ExceptionIoHandler.sessionIdle(IoSession, IdleStatus)
void exceptionCaught(Throwable cause)
throws Exception
IoHandler
implementation or by MINA. If cause is instanceof
IOException, MINA will close the connection automatically.
cause - the caught exception
ExceptionIoHandler.exceptionCaught(IoSession, Throwable)
void messageReceived(Object message)
throws Exception
message - the received message
ExceptionIoHandler.messageReceived(IoSession, Object)
void messageSent(Object message)
throws Exception
IoSession.write(Object) is sent out actually.
message - the sent message
ExceptionIoHandler.messageSent(IoSession, Object)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||