db

package
v0.0.0-...-8e00e62 Latest Latest
Warning

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

Go to latest
Published: Apr 7, 2019 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 BoltDB

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

func (*BoltDB) GetAll

func (bc *BoltDB) GetAll() Items

GetAll returns all key value pairs in the db

func (*BoltDB) GetValue

func (bc *BoltDB) GetValue(key string) ([]byte, error)

GetValue return the value of a specified key

func (*BoltDB) Initialize

func (bc *BoltDB) Initialize() error

Initialize the db

func (*BoltDB) SetValue

func (bc *BoltDB) SetValue(key string, value string) error

SetValue create a key value pair

type DbClient

type DbClient interface {
	Initialize() error
	SetValue(key string, value string) error
	GetValue(key string) ([]byte, error)
	GetAll() Items
}

type Items

type Items map[string]string

Jump to

Keyboard shortcuts

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