org.apache.mina.examples.reverser
Class ReverseProtocolHandler

java.lang.Object
  extended by org.apache.mina.protocol.ProtocolHandlerAdapter
      extended by org.apache.mina.examples.reverser.ReverseProtocolHandler
All Implemented Interfaces:
ProtocolHandler

public class ReverseProtocolHandler
extends ProtocolHandlerAdapter

ProtocolHandler implementation of reverser server protocol.

Version:
$Rev: 332218 $, $Date: 2005-11-10 12:52:42 +0900 $,
Author:
The Apache Directory Project (dev@directory.apache.org)

Constructor Summary
ReverseProtocolHandler()
           
 
Method Summary
 void exceptionCaught(ProtocolSession session, Throwable cause)
          Invoked when any exception is thrown by user ProtocolHandler implementation or by MINA.
 void messageReceived(ProtocolSession session, Object message)
          Invoked when protocol message is received.
 
Methods inherited from class org.apache.mina.protocol.ProtocolHandlerAdapter
messageSent, sessionClosed, sessionCreated, sessionIdle, sessionOpened
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ReverseProtocolHandler

public ReverseProtocolHandler()
Method Detail

exceptionCaught

public void exceptionCaught(ProtocolSession session,
                            Throwable cause)
Description copied from interface: ProtocolHandler
Invoked when any exception is thrown by user ProtocolHandler implementation or by MINA. If cause is instanceof IOException, MINA will close the connection automatically.

Specified by:
exceptionCaught in interface ProtocolHandler
Overrides:
exceptionCaught in class ProtocolHandlerAdapter

messageReceived

public void messageReceived(ProtocolSession session,
                            Object message)
Description copied from interface: ProtocolHandler
Invoked when protocol message is received. Implement your protocol flow here.

Specified by:
messageReceived in interface ProtocolHandler
Overrides:
messageReceived in class ProtocolHandlerAdapter


Copyright © 2004-2005 . All Rights Reserved.