|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--org.isam.exehda.HierarchicalId
Abstract super-class of all system-wide unique IDs. In order to guarantee unicity such IDs are build hierarchically. Hierarchical IDs are build up of two parts a parent ID as a local ID. Unicity is ensured if, for a given parent ID, the chosen local ID is unique.
ApplicationId
,
HostId
,
CellId
,
ObjectId
,
Serialized FormConstructor Summary | |
protected |
HierarchicalId(HierarchicalId parentId)
Creates a new HierachicalId instance. |
Method Summary | |
boolean |
equals(java.lang.Object o)
Implements HierarchicalId equality semantics. |
protected abstract java.lang.Object |
getLocalId()
Subclasses must overwrite this method and return an Object representation of the local id. |
HierarchicalId |
getParentId()
Returns the parent Id of this Id. |
protected abstract java.lang.String |
getType()
Subclasses must overwrite this method and return a String
representation of the ID's type. |
int |
hashCode()
Implements the hash code semantics for HierarchicalId objects so
that those object would be used as keys in a java.util Hashtable .
|
boolean |
isRoot()
Returns whether this ID is a root ID. |
java.lang.String |
toString()
Returns a String representation of this ID suitable to be used in debug
messages. |
Methods inherited from class java.lang.Object |
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Constructor Detail |
protected HierarchicalId(HierarchicalId parentId)
HierachicalId
instance.
parentId
- the parent of the ID been instantiated; null means this is
a root ID.Method Detail |
public HierarchicalId getParentId()
public boolean isRoot()
public java.lang.String toString()
String
representation of this ID suitable to be used in debug
messages.
toString
in class java.lang.Object
public boolean equals(java.lang.Object o)
equals
in class java.lang.Object
o
- an Object
value
public int hashCode()
HierarchicalId
objects so
that those object would be used as keys in a java.util Hashtable
.
This is a reference implementation. Subclasses are highly encouraged to
overwrite this method with faster (optimized) implementations.
hashCode
in class java.lang.Object
protected abstract java.lang.String getType()
String
representation of the ID's type.
String
valueprotected abstract java.lang.Object getLocalId()
getLocalId()
is invoked.
Object
value
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |