Trie is a class providing the mechanism to store information
in a trie on char strings. It does not by itself store any
information, subclasses should be created to hold the information.
The Trie is accompanied by its subclass ObjectTrie which can store
objects in a trie.
int start;
next, i.e. the element with
numeric value start resides at index 0 in next.
int beyond;
next.
_builtin_.Any next;
start == beyond, this is the suffix String which leads up
to the value this node holds (if any). Otherwise, start > beyond
and this is a MutableObjectArray pointing to the next nodes, and
which is to be indexed with offset start.
deferred boolean isEmpty;
YES iff we can hold a value, i.e. if we do not yet hold a
value.
protected id
createNode String str
start int s
end int e
options int options;
str starting at s,
and ending at e. The TRIE_LOOKUP_PREFIX option is ignored. If
this node already exists, it is returned.
When the options include TRIE_FOLD_CASE, the str is inserted in
lower case.
protected id
findNode String str
start int s
end int e
options int options;
str starting at s, and
ending at e. Iff a prefix match is desired, the node returned is
the longest prefix match.
protected void pushSuffix int options;
OutputStream write OutputStream s;
deferred OutputStream writeValue OutputStream s;
ObjectTrie is a Trie which can hold an object.
public mutable _builtin_.Any value;
boolean isEmpty;
void pushSuffix int options;
_builtin_.Any
at String key
options int options;
void
set All object
at String key
options int options;
OutputStream writeValue OutputStream s;
_builtin_.Any at String key;
void set All object at String key;