public class NodeDelegate extends Object implements INode
INode
namely
containing the position in the tree related to a parent-node, the related
type and the corresponding hash recursivly computed.Constructor and Description |
---|
NodeDelegate(long pNodeKey,
long pParentKey,
long pHash)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
boolean |
equals(Object obj) |
long |
getDataKey()
Gets unique
IData key. |
com.google.common.hash.Funnel<IData> |
getFunnel()
Getting a Funnel for computing guava-based hashes.
|
long |
getHash()
Getting the persisted hash value for this node.
|
int |
getKind()
Gets the kind of the item (atomic value, element node, attribute
node....).
|
long |
getParentKey()
Gets key of the context item's parent.
|
int |
getTypeKey()
Gets value type of the item.
|
int |
hashCode() |
boolean |
hasParent()
Declares, whether the item has a parent.
|
void |
serialize(DataOutput pOutput)
Serializing to given dataput
|
void |
setHash(long pHash)
Setting the hash of this node including substructure.
|
void |
setParentKey(long pParentKey)
Setting the parent key.
|
void |
setTypeKey(int pTypeKey)
Setting the type key.
|
String |
toString() |
public NodeDelegate(long pNodeKey, long pParentKey, long pHash)
pNodeKey
- to be represented by this delegate.pParentKey
- to be represented by this delegatepHash
- to be represented by this delegatepublic int getKind()
public long getDataKey()
IData
key.
This key should be set over the IBucketWriteTrx.incrementDataKey
for getting the correct
offset
within retrievals.getDataKey
in interface IData
public long getParentKey()
getParentKey
in interface INode
public void setParentKey(long pParentKey)
setParentKey
in interface INode
pParentKey
- the parent to be set.public long getHash()
public void setHash(long pHash)
public int getTypeKey()
getTypeKey
in interface INode
public void setTypeKey(int pTypeKey)
setTypeKey
in interface INode
pTypeKey
- the type to be set.public boolean hasParent()
public void serialize(DataOutput pOutput) throws TTIOException
serialize
in interface IData
pOutput
- to serialize toTTIOException
Copyright © 2013. All Rights Reserved.