JBoss Marshalling 1.3.0.CR9

org.jboss.marshalling
Interface ObjectTable

All Known Implementing Classes:
ChainingObjectTable

public interface ObjectTable

A lookup mechanism for predefined object references. Some marshallers can use this to correlate to known object instances.


Nested Class Summary
static interface ObjectTable.Writer
          The object writer for a specific object.
 
Method Summary
 ObjectTable.Writer getObjectWriter(Object object)
          Determine whether the given object reference is a valid predefined reference.
 Object readObject(Unmarshaller unmarshaller)
          Read an instance from the stream.
 

Method Detail

getObjectWriter

ObjectTable.Writer getObjectWriter(Object object)
                                   throws IOException
Determine whether the given object reference is a valid predefined reference.

Parameters:
object - the candidate object
Returns:
the object writer, or null to use the default mechanism
Throws:
IOException - if an I/O error occurs

readObject

Object readObject(Unmarshaller unmarshaller)
                  throws IOException,
                         ClassNotFoundException
Read an instance from the stream. The instance will have been written by the getObjectWriter(Object) method's Writer instance, as defined above.

Parameters:
unmarshaller - the unmarshaller to read from
Returns:
the object instance
Throws:
IOException - if an I/O error occurs
ClassNotFoundException - if a class could not be found

JBoss Marshalling 1.3.0.CR9

Copyright © 2011 JBoss, a division of Red Hat, Inc.