leveldb

package module
v0.0.0-...-259d925 Latest Latest
Warning

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

Go to latest
Published: Jan 7, 2017 License: BSD-3-Clause Imports: 17 Imported by: 8

README

WARNING: This is an incomplete work-in-progress.

It is not ready for production use. Some features aren't implemented yet. Documentation is missing.

The LevelDB key-value database in the Go programming language.

To download and install from source: $ go get github.com/golang/leveldb

Unless otherwise noted, the LevelDB-Go source files are distributed under the BSD-style license found in the LICENSE file.

Documentation

Overview

Package leveldb provides an ordered key/value store.

BUG: This package is incomplete.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Batch

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

Batch is a sequence of Sets and/or Deletes that are applied atomically.

func (*Batch) Delete

func (b *Batch) Delete(key []byte)

Delete adds an action to the batch that deletes the entry for key.

func (*Batch) Set

func (b *Batch) Set(key, value []byte)

Set adds an action to the batch that sets the key to map to the value.

type DB

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

TODO: document DB.

func Open

func Open(dirname string, opts *db.Options) (*DB, error)

Open opens a LevelDB whose files live in the given directory.

func (*DB) Apply

func (d *DB) Apply(batch Batch, opts *db.WriteOptions) error

func (*DB) Close

func (d *DB) Close() error

func (*DB) Delete

func (d *DB) Delete(key []byte, opts *db.WriteOptions) error

func (*DB) Find

func (d *DB) Find(key []byte, opts *db.ReadOptions) db.Iterator

func (*DB) Get

func (d *DB) Get(key []byte, opts *db.ReadOptions) ([]byte, error)

func (*DB) Set

func (d *DB) Set(key, value []byte, opts *db.WriteOptions) error

Directories

Path Synopsis
Package bloom implements Bloom filters.
Package bloom implements Bloom filters.
cmd
ldbdump
The ldbdump program dumps the contents of LevelDB tables (.ldb files), formerly known as sorted string tables (.sst files).
The ldbdump program dumps the contents of LevelDB tables (.ldb files), formerly known as sorted string tables (.sst files).
Package crc implements the checksum algorithm used throughout leveldb.
Package crc implements the checksum algorithm used throughout leveldb.
Package db defines the interfaces for a key/value store.
Package db defines the interfaces for a key/value store.
Package memdb provides a memory-backed implementation of the db.DB interface.
Package memdb provides a memory-backed implementation of the db.DB interface.
Package memfs provides a memory-backed db.FileSystem implementation.
Package memfs provides a memory-backed db.FileSystem implementation.
Package record reads and writes sequences of records.
Package record reads and writes sequences of records.
Package table implements readers and writers of leveldb tables.
Package table implements readers and writers of leveldb tables.

Jump to

Keyboard shortcuts

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