Documentation
¶
Index ¶
- type Iterator
- func (it *Iterator) Close() error
- func (it *Iterator) Domain() (start, end []byte)
- func (it *Iterator) Error() error
- func (it *Iterator) IsDeleted() bool
- func (it *Iterator) Key() []byte
- func (it *Iterator) KeyCopy(dst []byte) []byte
- func (it *Iterator) Next()
- func (it *Iterator) Seek(key []byte)
- func (it *Iterator) UnsafeEntry() ([]byte, page.ValuePtr, byte)
- func (it *Iterator) UnsafeKey() []byte
- func (it *Iterator) UnsafeValue() []byte
- func (it *Iterator) Valid() bool
- func (it *Iterator) Value() []byte
- func (it *Iterator) ValueCopy(dst []byte) []byte
- type SkipList
- func (s *SkipList) Append(key, value []byte)
- func (s *SkipList) AppendDelete(key []byte)
- func (s *SkipList) AppendWithCallback(key, value []byte, flags uint8, cb func(k, v []byte) error) error
- func (s *SkipList) Count() int
- func (s *SkipList) Delete(key []byte)
- func (s *SkipList) DeleteWithCallback(key []byte, cb func(k, v []byte) error) error
- func (s *SkipList) Get(key []byte) ([]byte, bool, bool)
- func (s *SkipList) LastKey() []byte
- func (s *SkipList) NewIterator(start, end []byte) *Iterator
- func (s *SkipList) Put(key, value []byte)
- func (s *SkipList) PutWithCallback(key, value []byte, cb func(k, v []byte) error) error
- func (s *SkipList) Reset()
- func (s *SkipList) Size() int64
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Iterator ¶
type Iterator struct {
// contains filtered or unexported fields
}
Iterator support
func (*Iterator) UnsafeValue ¶
type SkipList ¶
type SkipList struct {
// contains filtered or unexported fields
}
SkipList is an arena-backed skiplist using chunked memory to eliminate resizing copy costs.
func (*SkipList) Append ¶
Append inserts a new key/value entry assuming the key is strictly greater than the current maximum key in the skiplist.
func (*SkipList) AppendDelete ¶
AppendDelete inserts a tombstone for key assuming the key is strictly greater than the current maximum key in the skiplist.
func (*SkipList) AppendWithCallback ¶
func (s *SkipList) AppendWithCallback(key, value []byte, flags uint8, cb func(k, v []byte) error) error
AppendWithCallback inserts a new entry assuming the key is strictly greater than the current maximum key in the skiplist.
func (*SkipList) DeleteWithCallback ¶
DeleteWithCallback marks deleted with callback.
func (*SkipList) LastKey ¶
LastKey returns the largest key currently in the skiplist, or nil if empty.
func (*SkipList) NewIterator ¶
func (*SkipList) PutWithCallback ¶
PutWithCallback inserts key/value, calling cb with views into the arena before linking.