nokeyiserr

package
v0.0.0-...-e884aa9 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 21, 2022 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Snapshot

type Snapshot struct {
	kvdb.Snapshot
}

func (*Snapshot) Get

func (w *Snapshot) Get(key []byte) ([]byte, error)

Get returns error if key isn't found

type Wrapper

type Wrapper struct {
	kvdb.Store
}

func Wrap

func Wrap(db kvdb.Store) *Wrapper

Wrap creates new Wrapper

func (*Wrapper) Get

func (w *Wrapper) Get(key []byte) ([]byte, error)

Get returns error if key isn't found

func (*Wrapper) GetSnapshot

func (w *Wrapper) GetSnapshot() (kvdb.Snapshot, error)

GetSnapshot returns a latest snapshot of the underlying DB. A snapshot is a frozen snapshot of a DB state at a particular point in time. The content of snapshot are guaranteed to be consistent.

The snapshot must be released after use, by calling Release method.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL