BACK_REFERENCE = 1 ;
The BACK_REFERENCE primitive represents an object whose serialization encoding begins before this point in the stream. It is this primitive which enables the encoding of arbitrary graphs of objects rather than just trees.
Whenever the serializer begins to encode or decode an object that it hasn't encountered before during the processing of this stream, it allocates a new objectStreamID. The root object being serialized has objectStreamID==0. Successive objects are assigned consecutive increasing integer objectStreamID's.
When the serializer encounters an object that it has already assigned an objectStreamID for, it emits a BACK_REFERENCE primitive containing that objectStreamID. On deserialization, a BACK_REFERENCE is replaced by a reference to the previously encoded object.
Objects are assigned objectStreamID's before their children are processed, so cyclic graphs can be represented.
None.
SerializedBackReferencePrimitiveObject {
Integer objectType; // == BACK_REFERENCE
Integer objectStreamID;
}
01 05 BACK_REFERENCE 5