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.
    • Method Detail

      • getObjectWriter

        ObjectTable.Writer getObjectWriter​(java.lang.Object object)
                                    throws java.io.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:
        java.io.IOException - if an I/O error occurs
      • readObject

        java.lang.Object readObject​(Unmarshaller unmarshaller)
                             throws java.io.IOException,
                                    java.lang.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:
        java.io.IOException - if an I/O error occurs
        java.lang.ClassNotFoundException - if a class could not be found