Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type BTree ¶
type BTree struct {
// contains filtered or unexported fields
}
BTree implements the sorted cache for cachekv store, we don't use MemDB here because cachekv is used extensively in sdk core path, we need it to be as fast as possible, while `MemDB` is mainly used as a mocking db in unit tests.
We choose tidwall/btree over google/btree here because it provides API to implement step iterator directly.
func (BTree) Copy ¶
Copy the tree. This is a copy-on-write operation and is very fast because it only performs a shadowed copy.
func (BTree) ReverseIterator ¶
Click to show internal directories.
Click to hide internal directories.