ternarytreap library

This library defines 2 Multimaps implemented as self balancing ternary trees allowing fast, memory efficient prefix searching over a set of String keys

  • TernaryTreapSet - Keys map to Set of Values.
  • TernaryTreapList - Keys map to Sequence of Values.

Balancing is achieved via Treap algorithm where each node is assigned a random priority and tree rotation used to maintain heap ordering.

Classes

PrefixMatcher
A TernaryTreap specialised for String values. [...]
TernaryTreap<V>
A self balancing Ternary search tree. [...]
TernaryTreapList<V>
A TernaryTreap that stores values in a List [...]
TernaryTreapSet<V>
A TernaryTreap that stores values in a Set [...]

Typedefs

KeyMapping(String str) → String
Often it is desirable to define equivalences between Key strings, for example for case insensitivity. [...]