Documentation
¶
Index ¶
- Constants
- type BitmapIndex
- func (i *BitmapIndex) Buffer() *bytes.Buffer
- func (i *BitmapIndex) DebugCompare(j *BitmapIndex) string
- func (i *BitmapIndex) Flush() []byte
- func (i *BitmapIndex) Merge(other *BitmapIndex) error
- func (i *BitmapIndex) NextActiveBit(position uint32) (uint32, error)
- func (i *BitmapIndex) SetActive(index uint32) error
- func (i *BitmapIndex) SetInactive(index uint32) error
- func (i *BitmapIndex) Size() int
- func (i *BitmapIndex) ToXDR() xdr.BitmapIndex
- type NamedIndices
- type TrieIndex
- func (index *TrieIndex) Get(key []byte) ([]byte, bool)
- func (index *TrieIndex) Iterate(f func(key, value []byte))
- func (i *TrieIndex) MarshalBinary() ([]byte, error)
- func (i *TrieIndex) Merge(other *TrieIndex) error
- func (i *TrieIndex) ReadFrom(r io.Reader) (int64, error)
- func (i *TrieIndex) UnmarshalBinary(bytes []byte) error
- func (index *TrieIndex) Upsert(key, value []byte) ([]byte, bool)
- func (i *TrieIndex) WriteTo(w io.Writer) (int64, error)
Constants ¶
View Source
const ( TrieIndexVersion = 1 HeaderHasPrefix = 0b0000_0001 HeaderHasValue = 0b0000_0010 HeaderHasChildren = 0b0000_0100 )
View Source
const BitmapIndexVersion = 1
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BitmapIndex ¶
type BitmapIndex struct {
// contains filtered or unexported fields
}
func NewBitmapIndex ¶
func NewBitmapIndex(b []byte) (*BitmapIndex, error)
func NewBitmapIndexFromXDR ¶
func NewBitmapIndexFromXDR(index xdr.BitmapIndex) *BitmapIndex
func (*BitmapIndex) Buffer ¶
func (i *BitmapIndex) Buffer() *bytes.Buffer
func (*BitmapIndex) DebugCompare ¶
func (i *BitmapIndex) DebugCompare(j *BitmapIndex) string
DebugCompare returns a string that compares this bitmap to another bitmap byte-by-byte in binary form as two columns.
func (*BitmapIndex) Flush ¶
func (i *BitmapIndex) Flush() []byte
Flush flushes the index data to byte slice in index format.
func (*BitmapIndex) Merge ¶
func (i *BitmapIndex) Merge(other *BitmapIndex) error
func (*BitmapIndex) NextActiveBit ¶
func (i *BitmapIndex) NextActiveBit(position uint32) (uint32, error)
NextActiveBit returns the next bit position (inclusive) where this index is active. "Inclusive" means that if it's already active at `position`, this returns `position`.
func (*BitmapIndex) SetActive ¶
func (i *BitmapIndex) SetActive(index uint32) error
func (*BitmapIndex) SetInactive ¶
func (i *BitmapIndex) SetInactive(index uint32) error
func (*BitmapIndex) Size ¶
func (i *BitmapIndex) Size() int
func (*BitmapIndex) ToXDR ¶
func (i *BitmapIndex) ToXDR() xdr.BitmapIndex
type NamedIndices ¶
type NamedIndices map[string]*BitmapIndex
type TrieIndex ¶
func (*TrieIndex) MarshalBinary ¶
func (*TrieIndex) UnmarshalBinary ¶
Click to show internal directories.
Click to hide internal directories.