Documentation
¶
Index ¶
- type BTree
- func (b *BTree) AscendGt(k Node, filter FilterFn, n int) []Node
- func (b *BTree) AscendGte(k Node, filter FilterFn, n int) []Node
- func (b *BTree) Delete(k Node)
- func (b *BTree) DescendLt(k Node, filter FilterFn, n int) []Node
- func (b *BTree) DescendLte(k Node, filter FilterFn, n int) []Node
- func (b *BTree) Get(k Node) Node
- func (b *BTree) Insert(v Node)
- func (b *BTree) Update(oldV Node, newV Node)
- func (b *BTree) UpdateOrInsert(oldV Node, newV Node)
- type FilterFn
- type Node
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BTree ¶
type BTree struct {
// contains filtered or unexported fields
}
BTree : wrapped b-tree
func (*BTree) AscendGt ¶
AscendGt : ascend get nodes(>k). k : anchor key filter : filter a node n : the max length of nodes to get
func (*BTree) AscendGte ¶
AscendGte : ascend get nodes(>=k). k : anchor key filter : filter a node n : the max length of nodes to get
func (*BTree) Delete ¶
Delete : delete node, actually, figure out a node which related node sort fields match.
func (*BTree) DescendLt ¶
DescendLt : descend get nodes(<k). k : anchor key filter : filter a node n : the max length of nodes to get
func (*BTree) DescendLte ¶
DescendLte : descend get nodes(<=k). k : anchor key filter : filter a node n : the max length of nodes to get
func (*BTree) UpdateOrInsert ¶
UpdateOrInsert : if ole node exists, update old node to new node, else insert new node to btree.