public class Trie<K extends Comparable<? super K>,V> extends Object
Trie.Evaluator
.
This must be equipped with a Monoid for V, to realizes the combination of data when combining Tries.
Modifier and Type | Class and Description |
---|---|
static interface |
Trie.Automaton<K,V> |
static class |
Trie.Evaluator<K extends Comparable<? super K>,V>
Realizes alebraic operation on Tries.
|
static class |
Trie.Functor<K extends Comparable<? super K>> |
static class |
Trie.Node<K extends Comparable<? super K>,V>
Immutable data, each instance represents one "cell" (inner node or leave) of
the whole Trie.
|
Modifier and Type | Method and Description |
---|---|
static <K extends Comparable<? super K>> |
append(Trie<K,Boolean> cont) |
Trie.Automaton<K,V> |
automaton(V bottom) |
static <K extends Comparable<? super K>> |
empty()
Empty Set, when using Tries to represent "sets of K*", by V=Boolean.
|
static <K extends Comparable<? super K>> |
epsilon()
Set containing the empty K-string, when using Tries to represent "sets of K*", by V=Boolean.
|
boolean |
equals(Object o) |
boolean |
equals(Trie t) |
int |
hashCode() |
static void |
main(String[] args) |
static <K extends Comparable<? super K>,V> |
sequence(V pre,
Iterable<? extends K> keys,
V post) |
static <K extends Comparable<? super K>> |
singleton(K key)
Singlteon set containing a K-string with length=1, when using Tries to
represent "sets of K*", by V=Boolean.
|
static <K extends Comparable<? super K>,V> |
singleton(V pre,
K key,
V post) |
String |
toString() |
static <K extends Comparable<? super K>,V> |
unit(V value) |
public boolean equals(Trie t)
public static <K extends Comparable<? super K>,V> Trie<K,V> unit(V value)
public static <K extends Comparable<? super K>,V> Trie<K,V> singleton(V pre, K key, V post)
public static <K extends Comparable<? super K>,V> Trie<K,V> sequence(V pre, Iterable<? extends K> keys, V post)
public static <K extends Comparable<? super K>> Trie<K,Boolean> empty()
public static <K extends Comparable<? super K>> Trie<K,Boolean> epsilon()
public static <K extends Comparable<? super K>> Trie<K,Boolean> singleton(K key)
public static <K extends Comparable<? super K>> Function<Boolean,Trie<K,Boolean>> append(Trie<K,Boolean> cont)
public Trie.Automaton<K,V> automaton(V bottom)
public static void main(String[] args)
see also the complete user documentation .