org.planx.xmlstore.references
Class RelativeReference
java.lang.Object
org.planx.xmlstore.references.RelativeReference
- All Implemented Interfaces:
- Serializable, Reference
public class RelativeReference
- extends Object
- implements Reference, Serializable
A RelativeReference consists of a Reference
and a path. The path is an integer array specifying, in order from the
origin, the indexes of children to visit in order to reach the Node
identified by this RelativeReference.
- Author:
- Thomas Ambus
- See Also:
- Serialized Form
CLASS_ID
public static final byte CLASS_ID
- See Also:
- Constant Field Values
RelativeReference
public RelativeReference(Reference root)
RelativeReference
public RelativeReference(Reference root,
int[] path)
RelativeReference
public RelativeReference(Reference root,
int childIndex)
RelativeReference
public RelativeReference(RelativeReference parent,
int childIndex)
getRoot
public Reference getRoot()
getPath
public int[] getPath()
equals
public boolean equals(Object o)
- Returns
true if and only if the specified object is a
RelativeReference consisting of a root equal to the
root of this reference, and a path equal to the path of this reference.
- Overrides:
equals in class Object
hashCode
public int hashCode()
- Overrides:
hashCode in class Object
toString
public String toString()
- Overrides:
toString in class Object
getStreamer
public static Streamer<RelativeReference> getStreamer()
getDiscriminator
public static Discriminator<RelativeReference> getDiscriminator()
getDiscriminator
public static Discriminator<RelativeReference> getDiscriminator(Memory memory)
Copyright © 2010. All Rights Reserved.