ligodb

package
v0.0.0-...-5d85a61 Latest Latest
Warning

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

Go to latest
Published: Feb 12, 2023 License: GPL-3.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

View Source
const IdealBatchSize = 100 * 1024

Variables

This section is empty.

Functions

This section is empty.

Types

type Batch

type Batch interface {
	Writer

	ValueSize() int

	Write() error

	Reset()

	Replay(w Writer) error
}

type Batcher

type Batcher interface {
	NewBatch() Batch
}

type Compacter

type Compacter interface {
	Compact(start []byte, limit []byte) error
}

type Database

type Database interface {
	Reader
	Writer
	Batcher
	Iteratee
	Stater
	Compacter
	io.Closer
}

type Iteratee

type Iteratee interface {
	NewIterator() Iterator

	NewIteratorWithPrefix(prefix []byte) Iterator
}

type Iterator

type Iterator interface {
	Next() bool

	Error() error

	Key() []byte

	Value() []byte

	Release()
}

type KeyValueStore

type KeyValueStore interface {
	Reader
	Writer
	Batcher
	Iteratee
	Stater
	Compacter
	io.Closer
}

type Reader

type Reader interface {
	Has(key []byte) (bool, error)

	Get(key []byte) ([]byte, error)
}

type Stater

type Stater interface {
	Stat(property string) (string, error)
}

type Writer

type Writer interface {
	Put(key []byte, value []byte) error

	Delete(key []byte) error
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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