Versions in this module Expand all Collapse all v0 v0.12.0 Dec 27, 2022 Changes in this version + const NextPosErrBadKey + const NextPosTerminate + func ForEachKey(keyer KY, searchPath P, visit func(k K) bool) error + type DeletionMode uint8 + const DeletionMode_TargetIfLeafNode + const DeletionMode_TargetNode + type ErrBadSearchPath struct + Pos int + SearchPath string + func (e *ErrBadSearchPath) Error() string + type KeyIter interface + FormatSearchPath func(s SearchType) string + Next func(s SearchType, pos int) (k KeyType, nextPos int) + type Keyer interface + CompareKey func(k1, k2 KeyType) int + JoinSearchPath func(s SearchType, k KeyType) SearchType + ZeroSearchPath func() SearchType + type MapNode struct + Value V + func (n *MapNode[P, K, V, KY]) Children(keyer KY) (ret []*MapNode[P, K, V, KY]) + func (n *MapNode[P, K, V, KY]) GetChild(keyer KY, key K) (child *MapNode[P, K, V, KY]) + func (n *MapNode[P, K, V, KY]) Key() K + func (n *MapNode[P, K, V, KY]) New(parent *MapNode[P, K, V, KY], key K) *MapNode[P, K, V, KY] + func (n *MapNode[P, K, V, KY]) SearchPath(gen KY) P + type MapTrie struct + Keyer KY + func NewMapTrie(keyer KY) *MapTrie[P, K, V, KY] + func (t *MapTrie[P, K, V, KY]) Delete(searchPath P, mode DeletionMode) (nodeDeleted *MapNode[P, K, V, KY], err error) + func (t *MapTrie[P, K, V, KY]) Get(searchPath P) (_ *MapNode[P, K, V, KY], exact bool, err error) + func (t *MapTrie[P, K, V, KY]) InOrder(visit func(*MapNode[P, K, V, KY]) bool) + func (t *MapTrie[P, K, V, KY]) Init() + func (t *MapTrie[P, K, V, KY]) LevelOrder(visit func(*MapNode[P, K, V, KY]) bool) + func (t *MapTrie[P, K, V, KY]) PostOrder(visit func(*MapNode[P, K, V, KY]) bool) + func (t *MapTrie[P, K, V, KY]) PreOrder(visit func(*MapNode[P, K, V, KY]) bool) + func (t *MapTrie[P, K, V, KY]) Root() *MapNode[P, K, V, KY] + func (t *MapTrie[P, K, V, KY]) Set(searchPath P, value V) (*MapNode[P, K, V, KY], error) + func (t *MapTrie[P, K, V, KY]) Walk(searchPath P, fn MapTrieWalkFunc[P, K, V, KY]) error + type MapTrieWalkFunc func(key K, n *MapNode[P, K, V, KY]) bool + type Node interface + Children func(KY) []Self + GetChild func(keyer KY, key K) Self + Key func() K + New func(parent Self, key K) Self + SearchPath func(KY) P + type PathKeyer struct + func (PathKeyer) CompareKey(k1, k2 string) int + func (PathKeyer) FormatSearchPath(s string) string + func (PathKeyer) JoinSearchPath(s, k string) string + func (PathKeyer) Next(s string, pos int) (k string, nextPos int) + func (PathKeyer) ZeroSearchPath() (zero string) + type PathTrieMapStore struct + type PathTrieSliceStore struct + type RuneKeyer struct + func (RuneKeyer) CompareKey(k1, k2 rune) int + func (RuneKeyer) FormatSearchPath(s string) string + func (RuneKeyer) JoinSearchPath(s string, k rune) string + func (RuneKeyer) Next(s string, pos int) (k rune, nextPos int) + func (RuneKeyer) ZeroSearchPath() (zero string) + type RuneTrieMapStore struct + type RuneTrieSliceStore struct + type SectionKeyer string + func (SectionKeyer) CompareKey(k1, k2 string) int + func (SectionKeyer) FormatSearchPath(s string) string + func (SectionKeyer) JoinSearchPath(s, k string) string + func (SectionKeyer) ZeroSearchPath() (zero string) + func (sep SectionKeyer) Next(s string, pos int) (k string, nextPos int) + type SliceNode struct + Value V + func (n *SliceNode[P, K, V, KY]) Children(KY) []*SliceNode[P, K, V, KY] + func (n *SliceNode[P, K, V, KY]) GetChild(keyer KY, key K) (child *SliceNode[P, K, V, KY]) + func (n *SliceNode[P, K, V, KY]) Key() K + func (n *SliceNode[P, K, V, KY]) New(parent *SliceNode[P, K, V, KY], key K) *SliceNode[P, K, V, KY] + func (n *SliceNode[P, K, V, KY]) SearchPath(gen KY) P + type SliceTrie struct + Keyer KY + func NewSliceTrie(keyer KY) *SliceTrie[P, K, V, KY] + func (t *SliceTrie[P, K, V, KY]) Delete(searchPath P, mode DeletionMode) (nodeDeleted *SliceNode[P, K, V, KY], err error) + func (t *SliceTrie[P, K, V, KY]) Get(searchPath P) (_ *SliceNode[P, K, V, KY], exact bool, err error) + func (t *SliceTrie[P, K, V, KY]) InOrder(visit func(*SliceNode[P, K, V, KY]) bool) + func (t *SliceTrie[P, K, V, KY]) Init() + func (t *SliceTrie[P, K, V, KY]) LevelOrder(visit func(*SliceNode[P, K, V, KY]) bool) + func (t *SliceTrie[P, K, V, KY]) PostOrder(visit func(*SliceNode[P, K, V, KY]) bool) + func (t *SliceTrie[P, K, V, KY]) PreOrder(visit func(*SliceNode[P, K, V, KY]) bool) + func (t *SliceTrie[P, K, V, KY]) Root() *SliceNode[P, K, V, KY] + func (t *SliceTrie[P, K, V, KY]) Set(searchPath P, value V) (*SliceNode[P, K, V, KY], error) + func (t *SliceTrie[P, K, V, KY]) Walk(searchPath P, fn SliceTrieWalkFunc[P, K, V, KY]) error + type SliceTrieWalkFunc func(key K, n *SliceNode[P, K, V, KY]) bool