org.granite.messaging.jmf.codec.std.impl
Class ObjectCodecImpl

java.lang.Object
  extended by org.granite.messaging.jmf.codec.std.impl.AbstractStandardCodec<T>
      extended by org.granite.messaging.jmf.codec.std.impl.AbstractIntegerStringCodec<Object>
          extended by org.granite.messaging.jmf.codec.std.impl.ObjectCodecImpl
All Implemented Interfaces:
ConditionalObjectCodec, StandardCodec<Object>, ObjectCodec, JMFConstants

public class ObjectCodecImpl
extends AbstractIntegerStringCodec<Object>
implements ObjectCodec

Author:
Franck WOLFF

Nested Class Summary
 
Nested classes/interfaces inherited from class org.granite.messaging.jmf.codec.std.impl.AbstractIntegerStringCodec
AbstractIntegerStringCodec.IntegerComponents, AbstractIntegerStringCodec.StringTypeHandler
 
Field Summary
protected static AbstractIntegerStringCodec.StringTypeHandler TYPE_HANDLER
           
 
Fields inherited from class org.granite.messaging.jmf.codec.std.impl.AbstractIntegerStringCodec
JMF_STRING_TYPE_HANDLER
 
Fields inherited from interface org.granite.messaging.jmf.JMFConstants
CLIENT_PERSISTENCE_COLLECTION_PACKAGE, JMF_1111_1010, JMF_1111_1011, JMF_1111_1100, JMF_1111_1101, JMF_1111_1110, JMF_1111_1111, JMF_ARRAY, JMF_ARRAY_LIST, JMF_BIG_DECIMAL, JMF_BIG_INTEGER, JMF_BOOLEAN, JMF_BOOLEAN_OBJECT, JMF_BYTE, JMF_BYTE_OBJECT, JMF_CHARACTER, JMF_CHARACTER_OBJECT, JMF_CLASS, JMF_DATE, JMF_DOUBLE, JMF_DOUBLE_OBJECT, JMF_ENUM, JMF_FLOAT, JMF_FLOAT_OBJECT, JMF_HASH_MAP, JMF_HASH_SET, JMF_INTEGER, JMF_INTEGER_OBJECT, JMF_LONG, JMF_LONG_OBJECT, JMF_NULL, JMF_OBJECT, JMF_OBJECT_END, JMF_SHORT, JMF_SHORT_OBJECT, JMF_SQL_DATE, JMF_SQL_TIME, JMF_SQL_TIMESTAMP, JMF_STRING, JMF_X011_1100, JMF_X011_1101, JMF_X011_1110, JMF_X011_1111, JMF_XX01_1110, JMF_XX01_1111, JMF_XXX0_1110, JMF_XXX0_1111, JMF_XXXX_0110, JMF_XXXX_0111, UTF8
 
Constructor Summary
ObjectCodecImpl()
           
 
Method Summary
 boolean canEncode(Object v)
           
 Object decode(InputContext ctx, int parameterizedJmfType)
           
protected  void decodeSerializable(InputContext ctx, Serializable v)
           
 void dump(DumpContext ctx, int parameterizedJmfType)
           
 void encode(OutputContext ctx, Object v)
           
protected  void encodeSerializable(OutputContext ctx, Serializable v)
           
 int getObjectType()
           
 
Methods inherited from class org.granite.messaging.jmf.codec.std.impl.AbstractIntegerStringCodec
intComponents, readIntData, readString, readString, writeIntData, writeString
 
Methods inherited from class org.granite.messaging.jmf.codec.std.impl.AbstractStandardCodec
escape, escape, escape, newBadTypeJMFEncodingException
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

TYPE_HANDLER

protected static final AbstractIntegerStringCodec.StringTypeHandler TYPE_HANDLER
Constructor Detail

ObjectCodecImpl

public ObjectCodecImpl()
Method Detail

getObjectType

public int getObjectType()
Specified by:
getObjectType in interface StandardCodec<Object>

canEncode

public boolean canEncode(Object v)
Specified by:
canEncode in interface ConditionalObjectCodec

encode

public void encode(OutputContext ctx,
                   Object v)
            throws IOException,
                   IllegalAccessException,
                   InvocationTargetException
Specified by:
encode in interface StandardCodec<Object>
Throws:
IOException
IllegalAccessException
InvocationTargetException

encodeSerializable

protected void encodeSerializable(OutputContext ctx,
                                  Serializable v)
                           throws IOException,
                                  IllegalAccessException,
                                  InvocationTargetException
Throws:
IOException
IllegalAccessException
InvocationTargetException

decode

public Object decode(InputContext ctx,
                     int parameterizedJmfType)
              throws IOException,
                     ClassNotFoundException,
                     InstantiationException,
                     IllegalAccessException,
                     InvocationTargetException,
                     SecurityException,
                     NoSuchMethodException
Specified by:
decode in interface StandardCodec<Object>
Throws:
IOException
ClassNotFoundException
InstantiationException
IllegalAccessException
InvocationTargetException
SecurityException
NoSuchMethodException

decodeSerializable

protected void decodeSerializable(InputContext ctx,
                                  Serializable v)
                           throws IOException,
                                  ClassNotFoundException,
                                  IllegalAccessException,
                                  InvocationTargetException
Throws:
IOException
ClassNotFoundException
IllegalAccessException
InvocationTargetException

dump

public void dump(DumpContext ctx,
                 int parameterizedJmfType)
          throws IOException
Specified by:
dump in interface StandardCodec<Object>
Throws:
IOException