Package eu.bandm.tools.ops
Class Trie.Node<K extends Comparable<? super K>,V>
java.lang.Object
eu.bandm.tools.ops.Trie.Node<K,V>
- Enclosing class:
- Trie<K extends Comparable<? super K>,
V>
Immutable data, each instance represents one cell (inner node or leaf) of
the whole Trie.
This class allows null as a V value (in contrast to Trie)
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionbranches()
boolean
boolean
final V
getValue()
int
hashCode()
static <K extends Comparable<? super K>,
V>
Trie.Node<K,V> protected static <K extends Comparable<? super K>,
V>
Trie.Node<K,V> static <K extends Comparable<? super K>,
V>
Trie.Node<K,V> singleton
(V pre, K key, V post) Create a cell labelled with the value and having one subnode with given key and post value.toString()
static <K extends Comparable<? super K>,
V>
Trie.Node<K,V> unit
(V value) Create a cell labelled with the value and having no subnodes.
-
Constructor Details
-
Node
-
-
Method Details
-
unit
Create a cell labelled with the value and having no subnodes. -
singleton
Create a cell labelled with the value and having one subnode with given key and post value. -
sequence
public static <K extends Comparable<? super K>,V> Trie.Node<K,V> sequence(V pre, Iterable<? extends K> keys, V post) -
sequence
protected static <K extends Comparable<? super K>,V> Trie.Node<K,V> sequence(V pre, Iterator<? extends K> keys, V post) -
getValue
-
branches
-
toString
-
hashCode
public int hashCode() -
equals
-
equals
-