Documentation ¶
Index ¶
Constants ¶
View Source
const (
KeyLength = 32 // Total bytes used for keys
)
Variables ¶
View Source
var ErrNotFound = errors.New("not found")
ErrNotFound is returned by KeyValueDB.Get if the key is not found.
View Source
var ErrNotOpen = errors.New("not open")
ErrNotOpen is returned by KeyValueDB.Get, .Put, and .Close if the database is not open.
Functions ¶
This section is empty.
Types ¶
type DebugBatch ¶ added in v0.5.1
type DebugBatch struct { Batch KeyValueTxn Logger Logger }
func (*DebugBatch) Commit ¶ added in v0.5.1
func (b *DebugBatch) Commit() error
func (*DebugBatch) Discard ¶ added in v0.5.1
func (b *DebugBatch) Discard()
type Key ¶
func (Key) MarshalJSON ¶
MarshalJSON is implemented for JSON-based logging
type KeyValueStore ¶
type KeyValueStore interface { Close() error // Returns an error if the close fails Begin(writable bool) KeyValueTxn }
type KeyValueTxn ¶
Click to show internal directories.
Click to hide internal directories.