database

package
v0.0.0-...-30c1b5e Latest Latest
Warning

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

Go to latest
Published: Sep 22, 2021 License: GPL-3.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Badger

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

func (Badger) Close

func (d Badger) Close() error

func (Badger) Delete

func (d Badger) Delete(key []byte) error

func (Badger) DeleteAll

func (d Badger) DeleteAll() error

func (Badger) Get

func (d Badger) Get(key []byte) ([]byte, error)

func (Badger) GetAllKeys

func (d Badger) GetAllKeys() ([][]byte, error)

func (Badger) Set

func (d Badger) Set(key []byte, value []byte) error

type Database

type Database interface {
	Set(key, value []byte) error
	Delete(key []byte) error
	DeleteAll() error
	Get(key []byte) ([]byte, error)
	GetAllKeys() ([][]byte, error)
	Close() error
}

func Open

func Open(path string) (Database, error)

Jump to

Keyboard shortcuts

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