Documentation ¶
Index ¶
- Variables
- type Cache
- type Compact
- func (c *Compact) Compact(fn db.ProgressCB, newFd, oldFd uintptr) int
- func (c *Compact) CompactReadEntry(fd uintptr, at int, index int) []byte
- func (c *Compact) CompactReadKey(fd uintptr, at int64) ([]byte, []byte)
- func (c *Compact) CompactUpdateLink(fd uintptr, at int, index int, pointer int64, kind int)
- func (c *Compact) CompactWriteHeader(fd uintptr, at int, index int) int64
- func (c *Compact) CompactWriteKey(fd uintptr, key, value []byte) int64
- func (c *Compact) Maintain(fn *db.ProgressCB)
- func (c *Compact) Open(file string, startEmpty bool) uintptr
- type File
- type FileFlatDB
- func (f *FileFlatDB) Close()
- func (f *FileFlatDB) Del(key []uint8)
- func (f *FileFlatDB) Drop()
- func (f *FileFlatDB) Empty()
- func (f *FileFlatDB) FindKey(key *NibbleBuffer, doCreate bool) *Key
- func (f *FileFlatDB) Get(key []uint8) []uint8
- func (f *FileFlatDB) Maintain(fn *db.ProgressCB) error
- func (f *FileFlatDB) Open()
- func (f *FileFlatDB) Put(key, value []uint8)
- func (f *FileFlatDB) ReadValue(key *Key) *Value
- func (f *FileFlatDB) Rename(base, file string)
- func (f *FileFlatDB) Size() int
- func (f *FileFlatDB) WriteValue(key *Key, value []byte) *Value
- type Impl
- func (i *Impl) ExtractValueInfo(keyValue []byte) *ValueInfo
- func (i *Impl) FindKey(key *NibbleBuffer, doCreate bool, keyIndex, branchAt int64) *Key
- func (i *Impl) GetKeyValue(keyAt int64) []byte
- func (i *Impl) ReadValue(keyValue []byte) *Value
- func (i *Impl) RetrieveBranch(doCreate bool, branch []byte, entryIndex int, keyIndex int, key *NibbleBuffer) *Key
- func (i *Impl) RetrieveEmpty(doCreate bool, branch []byte, branchAt int64, entryIndex int64, ...) *Key
- func (i *Impl) RetrieveLeaf(doCreate bool, branch []byte, branchAt int, entryIndex int, keyIndex int, ...) *Key
- func (i *Impl) WriteNewBranch(branch []byte, branchAt int64, entryIndex int64, key *NibbleBuffer, ...) *Key
- func (i *Impl) WriteNewBuffer(buffer []byte, withCache bool) int64
- func (i *Impl) WriteNewBuffers(buffers [][]byte) int64
- func (i *Impl) WriteNewKey(key *NibbleBuffer) *Key
- func (i *Impl) WriteNewLeaf(branch []byte, branchAt int64, entryIndex int64, key *NibbleBuffer) *Key
- func (i *Impl) WriteUpdatedBuffer(buffer []byte, bufferAt int64) int64
- func (i *Impl) WriteValue(keyAt int, keyValue []byte, value []byte) *Value
- type Key
- type LruMap
- type NibbleBuffer
- type Serializer
- type Value
- type ValueInfo
Constants ¶
This section is empty.
Variables ¶
View Source
var SlotBranch = 1
SlotBranch ...
View Source
var SlotEmpty = 0
SlotEmpty ...
View Source
var SlotLeaf = 2
SlotLeaf ...
Functions ¶
This section is empty.
Types ¶
type Cache ¶
type Cache struct {
// contains filtered or unexported fields
}
Cache ...
func (*Cache) CacheBranch ¶
CacheBranch ...
func (*Cache) GetCachedBranch ¶
GetCachedBranch ...
type Compact ¶
type Compact struct {
// contains filtered or unexported fields
}
Compact ...
func (*Compact) Compact ¶
func (c *Compact) Compact(fn db.ProgressCB, newFd, oldFd uintptr) int
Compact ...
func (*Compact) CompactReadEntry ¶
CompactReadEntry ...
func (*Compact) CompactReadKey ¶
CompactReadKey ...
func (*Compact) CompactUpdateLink ¶
CompactUpdateLink ...
func (*Compact) CompactWriteHeader ¶
CompactWriteHeader ...
func (*Compact) CompactWriteKey ¶
CompactWriteKey ...
type FileFlatDB ¶
type FileFlatDB struct {
// contains filtered or unexported fields
}
FileFlatDB ...
func (*FileFlatDB) FindKey ¶
func (f *FileFlatDB) FindKey(key *NibbleBuffer, doCreate bool) *Key
FindKey ...
func (*FileFlatDB) WriteValue ¶
func (f *FileFlatDB) WriteValue(key *Key, value []byte) *Value
WriteValue ...
type Impl ¶
type Impl struct {
// contains filtered or unexported fields
}
Impl ...
func (*Impl) ExtractValueInfo ¶
ExtractValueInfo ...
func (*Impl) FindKey ¶
func (i *Impl) FindKey(key *NibbleBuffer, doCreate bool, keyIndex, branchAt int64) *Key
FindKey ...
func (*Impl) RetrieveBranch ¶
func (i *Impl) RetrieveBranch(doCreate bool, branch []byte, entryIndex int, keyIndex int, key *NibbleBuffer) *Key
RetrieveBranch ...
func (*Impl) RetrieveEmpty ¶
func (i *Impl) RetrieveEmpty(doCreate bool, branch []byte, branchAt int64, entryIndex int64, key *NibbleBuffer) *Key
RetrieveEmpty ...
func (*Impl) RetrieveLeaf ¶
func (i *Impl) RetrieveLeaf(doCreate bool, branch []byte, branchAt int, entryIndex int, keyIndex int, key *NibbleBuffer) *Key
RetrieveLeaf ...
func (*Impl) WriteNewBranch ¶
func (i *Impl) WriteNewBranch(branch []byte, branchAt int64, entryIndex int64, key *NibbleBuffer, prevAt int64, prevKey *NibbleBuffer, matchIndex uint64, depth int64) *Key
WriteNewBranch ...
func (*Impl) WriteNewBuffer ¶
WriteNewBuffer ...
func (*Impl) WriteNewBuffers ¶
WriteNewBuffers ...
func (*Impl) WriteNewLeaf ¶
func (i *Impl) WriteNewLeaf(branch []byte, branchAt int64, entryIndex int64, key *NibbleBuffer) *Key
WriteNewLeaf ...
func (*Impl) WriteUpdatedBuffer ¶
WriteUpdatedBuffer ...
type Serializer ¶
type Serializer struct {
IsCompressed bool
}
Serializer ...
func (*Serializer) DeserializeValue ¶
func (s *Serializer) DeserializeValue(value []byte) []uint8
DeserializeValue ...
func (*Serializer) SerializeKey ¶
func (s *Serializer) SerializeKey(value []uint8) *NibbleBuffer
SerializeKey ...
func (*Serializer) SerializeValue ¶
func (s *Serializer) SerializeValue(value []uint8) []byte
SerializeValue ...
Click to show internal directories.
Click to hide internal directories.