public class ImageServerIoHandler extends IoHandlerAdapter
IoHandler
限定符和类型 | 字段和说明 |
---|---|
static java.lang.String |
INDEX_KEY |
构造器和说明 |
---|
ImageServerIoHandler() |
限定符和类型 | 方法和说明 |
---|---|
void |
exceptionCaught(IoSession session,
java.lang.Throwable cause)
This method will be called whenever an exception occurs.
|
void |
messageReceived(IoSession session,
java.lang.Object message)
Handle incoming messages.
|
void |
sessionOpened(IoSession session)
Called when the session is opened, which will come after the session created.
|
inputClosed, messageSent, sessionClosed, sessionCreated, sessionIdle
public void sessionOpened(IoSession session) throws java.lang.Exception
sessionOpened
在接口中 IoHandler
sessionOpened
在类中 IoHandlerAdapter
session
- The session being openedjava.lang.Exception
- If we get an exception while processing the open eventIoHandlerAdapter.sessionOpened(org.apache.mina.core.session.IoSession)
public void exceptionCaught(IoSession session, java.lang.Throwable cause) throws java.lang.Exception
exceptionCaught
在接口中 IoHandler
exceptionCaught
在类中 IoHandlerAdapter
session
- The session for which we have got an exceptioncause
- The exception that has been caughtjava.lang.Exception
- If we get an exception while processing the caught exceptionIoHandlerAdapter.exceptionCaught(org.apache.mina.core.session.IoSession, java.lang.Throwable)
public void messageReceived(IoSession session, java.lang.Object message) throws java.lang.Exception
messageReceived
在接口中 IoHandler
messageReceived
在类中 IoHandlerAdapter
session
- The session that is receiving a messagemessage
- The received messagejava.lang.Exception
- If we get an exception while processing the received messageIoHandlerAdapter.messageReceived(org.apache.mina.core.session.IoSession, java.lang.Object)