net.sf.cindy.decoder
Class SerialDecoder

java.lang.Object
  extended by net.sf.cindy.decoder.SerialDecoder
All Implemented Interfaces:
PacketDecoder

public class SerialDecoder
extends java.lang.Object
implements PacketDecoder

Decode Packet to serial object.

Version:
$id$
Author:
Roger Chen

Constructor Summary
SerialDecoder()
           
 
Method Summary
 java.lang.Object decode(Session session, Packet packet)
          Decode packet to object.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SerialDecoder

public SerialDecoder()
Method Detail

decode

public java.lang.Object decode(Session session,
                               Packet packet)
                        throws java.lang.Exception
Description copied from interface: PacketDecoder
Decode packet to object. The content of the packet is readonly, and it's position will not be changed if the method return null.

Specified by:
decode in interface PacketDecoder
Parameters:
session - session
packet - packet
Returns:
decoded object
Throws:
java.lang.Exception - any exception