leveldb

package
v0.0.1 Latest Latest
Warning

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

Go to latest
Published: Oct 16, 2019 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CreateDirIfMissing

func CreateDirIfMissing(dir string) (bool, error)

func DirEmpty

func DirEmpty(dir string) (bool, error)

Types

type Conf

type Conf struct {
	Path string
}

type DB

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

func NewDB

func NewDB(conf *Conf) *DB

func (*DB) Close

func (db *DB) Close()

func (*DB) Delete

func (db *DB) Delete(key []byte, sync bool) error

func (*DB) Get

func (db *DB) Get(key []byte) ([]byte, error)

func (*DB) GetIterator

func (db *DB) GetIterator(startKey, endKey []byte) iterator.Iterator

func (*DB) Open

func (db *DB) Open()

func (*DB) Put

func (db *DB) Put(key, value []byte, sync bool) error

func (*DB) WriteBatch

func (db *DB) WriteBatch(batch *leveldb.Batch, sync bool) error

Jump to

Keyboard shortcuts

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