|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectit.unimi.dsi.mg4j.util.ImmutableBinaryTrie.Node
protected static class ImmutableBinaryTrie.Node
A node in the trie.
Field Summary | |
---|---|
ImmutableBinaryTrie.Node |
left
|
long[] |
path
An array containing the path compacted in this node ( null if there is no compaction at this node). |
int |
pathLength
The length of the path compacted in this node (0 if there is no compaction at this node). |
ImmutableBinaryTrie.Node |
right
|
int |
word
If nonnegative, this node represent the word -th word. |
Constructor Summary | |
---|---|
ImmutableBinaryTrie.Node(BitVector path)
Creates a node that does not represent a word. |
|
ImmutableBinaryTrie.Node(BitVector path,
int word)
Creates a node representing a word. |
Method Summary | |
---|---|
boolean |
isLeaf()
Returns true if this node is a leaf. |
String |
toString()
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public ImmutableBinaryTrie.Node left
public ImmutableBinaryTrie.Node right
public final long[] path
null
if there is no compaction at this node).
public final int pathLength
public final int word
word
-th word.
Constructor Detail |
---|
public ImmutableBinaryTrie.Node(BitVector path, int word)
Note that the long array contained in path
will be stored inside the node.
path
- the path compacted in this node, or null
for the empty path.word
- the index of the word represented by this node.public ImmutableBinaryTrie.Node(BitVector path)
path
- the path compacted in this node, or null
for the empty path.Method Detail |
---|
public boolean isLeaf()
public String toString()
toString
in class Object
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |