keyvalue

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Feb 14, 2019 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type IterableKeyVal

type IterableKeyVal interface {
	KeyValue
	NewKeyIterator(prefix []byte) (Iterator, error)
}

type Iterator

type Iterator interface {
	Key() []byte
	Value() []byte
	Next() bool
	Error() error
	Release()
}

type KeyVal

type KeyVal struct {
	// contains filtered or unexported fields
}

func NewKeyVal

func NewKeyVal(path string, withBatch bool) (*KeyVal, error)

func (*KeyVal) Delete

func (k *KeyVal) Delete(key []byte) error

func (*KeyVal) Flush

func (k *KeyVal) Flush() error

func (*KeyVal) Get

func (k *KeyVal) Get(key []byte) ([]byte, error)

func (*KeyVal) Has

func (k *KeyVal) Has(key []byte) (bool, error)

func (*KeyVal) NewKeyIterator

func (k *KeyVal) NewKeyIterator(prefix []byte) (Iterator, error)

func (*KeyVal) Put

func (k *KeyVal) Put(key, val []byte) error

type KeyValue

type KeyValue interface {
	Has(key []byte) (bool, error)
	Put(key, val []byte) error
	Get(key []byte) ([]byte, error)
	Delete(key []byte) error
	Flush() error
}

Jump to

Keyboard shortcuts

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