Modifier and Type | Field and Description |
---|---|
protected int |
index
The Index.
|
protected CharTrie |
trie
The Trie.
|
Constructor and Description |
---|
TrieNode(CharTrie trie,
int index)
Instantiates a new Trie node.
|
TrieNode(CharTrie trie,
int index,
TrieNode parent)
Instantiates a new Trie node.
|
Modifier and Type | Method and Description |
---|---|
Bits |
bitsTo(TrieNode toNode)
Bits to bits.
|
boolean |
containsCursor(long cursorId)
Contains cursor boolean.
|
protected void |
decrementCursorCount(long count)
Decrement cursor count.
|
boolean |
equals(Object o) |
char |
getChar()
Gets char.
|
Optional<? extends TrieNode> |
getChild(char token)
Gets child.
|
Stream<? extends TrieNode> |
getChildren()
Gets children.
|
TreeMap<Character,? extends TrieNode> |
getChildrenMap()
Gets children map.
|
TrieNode |
getContinuation(char c)
Gets continuation.
|
long |
getCursorCount()
Gets cursor count.
|
long |
getCursorIndex()
Gets cursor index.
|
String |
getDebugString()
Gets debug string.
|
String |
getDebugString(TrieNode root)
Gets debug string.
|
CharSequence |
getDebugToken()
Gets debug token.
|
short |
getDepth()
Gets depth.
|
Map<Character,TrieNode> |
getGodChildren()
Gets god children.
|
short |
getNumberOfChildren()
Gets number of children.
|
TrieNode |
getParent()
Gets parent.
|
String |
getRawString()
Gets raw string.
|
String |
getString()
Gets string.
|
String |
getString(TrieNode root)
Gets string.
|
String |
getToken()
Gets token.
|
CharTrie |
getTrie()
Gets trie.
|
TrieNode |
godparent()
Godparent trie node.
|
boolean |
hasChildren()
Has children boolean.
|
int |
hashCode() |
Interval |
intervalTo(TrieNode toNode)
Interval to interval.
|
boolean |
isStringTerminal()
Is string terminal boolean.
|
protected TrieNode |
newNode(int index)
New node trie node.
|
TrieNode |
refresh()
Refresh trie node.
|
void |
removeCursorCount()
Remove cursor count.
|
Stream<? extends TrieNode> |
streamDecendents(int level)
Stream decendents stream.
|
TrieNode |
traverse(long cursorId)
Traverse trie node.
|
TrieNode |
traverse(String str)
Traverse trie node.
|
TrieNode |
visitFirst(Consumer<? super TrieNode> visitor)
Visit first trie node.
|
TrieNode |
visitLast(Consumer<? super TrieNode> visitor)
Visit last trie node.
|
protected final CharTrie trie
protected final int index
public TrieNode(CharTrie trie, int index)
trie
- the trieindex
- the indexpublic TrieNode godparent()
protected TrieNode newNode(int index)
index
- the indexpublic TrieNode refresh()
public String getString(TrieNode root)
root
- the rootpublic String getRawString()
public String getString()
public String getDebugString()
public String getDebugString(TrieNode root)
root
- the rootpublic CharSequence getDebugToken()
public String getToken()
public char getChar()
public short getNumberOfChildren()
public short getDepth()
public long getCursorIndex()
public long getCursorCount()
public TrieNode visitFirst(Consumer<? super TrieNode> visitor)
visitor
- the visitorpublic TrieNode visitLast(Consumer<? super TrieNode> visitor)
visitor
- the visitorpublic Optional<? extends TrieNode> getChild(char token)
token
- the tokenprotected void decrementCursorCount(long count)
count
- the countpublic TrieNode traverse(String str)
str
- the strpublic boolean containsCursor(long cursorId)
cursorId
- the cursor idpublic TrieNode traverse(long cursorId)
cursorId
- the cursor idpublic void removeCursorCount()
public Bits bitsTo(TrieNode toNode)
toNode
- the to nodepublic Interval intervalTo(TrieNode toNode)
toNode
- the to nodepublic boolean hasChildren()
public CharTrie getTrie()
public boolean isStringTerminal()
public Stream<? extends TrieNode> streamDecendents(int level)
level
- the levelpublic TreeMap<Character,? extends TrieNode> getChildrenMap()
public Map<Character,TrieNode> getGodChildren()
public TrieNode getParent()
public TrieNode getContinuation(char c)
c
- the cCopyright © 2019 SimiaCryptus Software. All rights reserved.