K
- the type of the keys in this mapV
- the type of the values in this mappublic interface Trie<K,V> extends IterableSortedMap<K,V>
Modifier and Type | Method and Description |
---|---|
SortedMap<K,V> |
prefixMap(K key)
Returns a view of this
Trie of all elements that are prefixed
by the given key. |
comparator, entrySet, firstKey, headMap, keySet, lastKey, subMap, tailMap, values
firstKey, lastKey, mapIterator, nextKey, previousKey
clear, compute, computeIfAbsent, computeIfPresent, containsKey, containsValue, equals, forEach, get, getOrDefault, hashCode, isEmpty, merge, put, putAll, putIfAbsent, remove, remove, replace, replace, replaceAll, size
containsKey, containsValue, entrySet, get, isEmpty, keySet, remove, size, values
SortedMap<K,V> prefixMap(K key)
Trie
of all elements that are prefixed
by the given key.
In a Trie
with fixed size keys, this is essentially a
Map.get(Object)
operation.
For example, if the Trie
contains 'Anna', 'Anael',
'Analu', 'Andreas', 'Andrea', 'Andres', and 'Anatole', then
a lookup of 'And' would return 'Andreas', 'Andrea', and 'Andres'.
Copyright © 2001–2018 The Apache Software Foundation. All rights reserved.