com.caucho.hessian.io
Interface Deserializer

All Known Implementing Classes:
AbstractDeserializer, AbstractListDeserializer, AbstractMapDeserializer, AbstractStreamDeserializer, AbstractStringValueDeserializer, AnnotationDeserializer, ArrayDeserializer, BasicDeserializer, BeanDeserializer, BigDecimalDeserializer, ClassDeserializer, CollectionDeserializer, EnumDeserializer, EnumerationDeserializer, FileDeserializer, InputStreamDeserializer, IteratorDeserializer, JavaDeserializer, MapDeserializer, MBeanAttributeInfoDeserializer, MBeanConstructorInfoDeserializer, MBeanInfoDeserializer, MBeanNotificationInfoDeserializer, MBeanOperationInfoDeserializer, MBeanParameterInfoDeserializer, ObjectDeserializer, ObjectInstanceDeserializer, ObjectNameDeserializer, RemoteDeserializer, SqlDateDeserializer, StackTraceElementDeserializer, StringValueDeserializer, UnsafeDeserializer, ValueDeserializer

public interface Deserializer

Deserializing an object. Custom deserializers should extend from AbstractDeserializer to avoid issues with signature changes.


Method Summary
 Object createField(String name)
          Returns the deserializer's field reader for the given name.
 Object[] createFields(int len)
          Creates an empty array for the deserializers field entries.
 Class<?> getType()
           
 boolean isReadResolve()
           
 Object readLengthList(AbstractHessianInput in, int length)
           
 Object readList(AbstractHessianInput in, int length)
           
 Object readMap(AbstractHessianInput in)
           
 Object readObject(AbstractHessianInput in)
           
 Object readObject(AbstractHessianInput in, Object[] fields)
          Reads the object from the input stream, given the field definition.
 Object readObject(AbstractHessianInput in, String[] fieldNames)
           
 

Method Detail

getType

Class<?> getType()

isReadResolve

boolean isReadResolve()

readObject

Object readObject(AbstractHessianInput in)
                  throws IOException
Throws:
IOException

readList

Object readList(AbstractHessianInput in,
                int length)
                throws IOException
Throws:
IOException

readLengthList

Object readLengthList(AbstractHessianInput in,
                      int length)
                      throws IOException
Throws:
IOException

readMap

Object readMap(AbstractHessianInput in)
               throws IOException
Throws:
IOException

createFields

Object[] createFields(int len)
Creates an empty array for the deserializers field entries.

Parameters:
len - number of fields to be read
Returns:
empty array of the proper field type.

createField

Object createField(String name)
Returns the deserializer's field reader for the given name.

Parameters:
name - the field name
Returns:
the deserializer's internal field reader

readObject

Object readObject(AbstractHessianInput in,
                  Object[] fields)
                  throws IOException
Reads the object from the input stream, given the field definition.

Parameters:
in - the input stream
fields - the deserializer's own field marshal
Returns:
the new object
Throws:
IOException

readObject

Object readObject(AbstractHessianInput in,
                  String[] fieldNames)
                  throws IOException
Throws:
IOException


Copyright © 2013. All Rights Reserved.