dbBolt

package module
v0.0.2 Latest Latest
Warning

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

Go to latest
Published: Jun 4, 2021 License: MIT Imports: 5 Imported by: 4

README

go-boltdb

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BoltDbBackend

type BoltDbBackend struct {
	// contains filtered or unexported fields
}
var BoltBackend BoltDbBackend

func (*BoltDbBackend) ConnectionEstablish

func (backend *BoltDbBackend) ConnectionEstablish(callback func(connection DatabaseBackendConnection) error) error

func (*BoltDbBackend) Initialize

func (backend *BoltDbBackend) Initialize(databaseFileName string, verbose bool, blotModels ...BoltModel) error

type BoltModel

type BoltModel interface {
	PrimaryKey() string
	Bucket() []byte
}

type DatabaseBackend

type DatabaseBackend interface {
	Initialize(databaseFile string, verbose bool, blotModels ...BoltModel) error
	ConnectionEstablish(callback func(connection DatabaseBackendConnection) error) error
}

type DatabaseBackendConnection

type DatabaseBackendConnection interface {
	CreateDatabase(model BoltModel) error
	FindAll(dataSlice interface{}) error
	FindById(id string, data BoltModel) error
	Persist(data BoltModel) error
	SaveOrUpdate(data BoltModel) error
	Delete(data BoltModel) error
}

Jump to

Keyboard shortcuts

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