storage

package
v0.1.1-0...-d12b490 Latest Latest
Warning

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

Go to latest
Published: Nov 29, 2015 License: Apache-2.0 Imports: 7 Imported by: 1

Documentation

Index

Constants

View Source
const DEFAULT_STORAGE_ENGINE = "ldb"

Variables

This section is empty.

Functions

func RegisterStorageEngine

func RegisterStorageEngine(name string, fn func(path string) (Storage, error))

Types

type Storage

type Storage interface {
	Set(k, v []byte) error
	Get(k []byte) ([]byte, error)
	Delete(k []byte) error
	ForEach(fn func(k, v []byte) error) error
	Close() error
	WALName() string
}

func OpenLeveldbStorage

func OpenLeveldbStorage(path string) (Storage, error)

func OpenStorage

func OpenStorage(path string) (Storage, error)

Jump to

Keyboard shortcuts

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