temporary

package
v0.0.0-...-59e56fa Latest Latest
Warning

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

Go to latest
Published: Apr 1, 2020 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DbMaker

type DbMaker func(ver uint64) (db kvdb.KeyValueStore, tables interface{})

DbMaker makes temporary database and related object (tables).

type Dbs

type Dbs struct {
	sync.Mutex
	logger.Instance
	// contains filtered or unexported fields
}

Dbs is a named sequence of temporary databases and related object (tables).

func NewDbs

func NewDbs(table kvdb.KeyValueStore, maker DbMaker) *Dbs

NewDbs constructor.

func (*Dbs) Del

func (t *Dbs) Del(ver uint64)

Del removes temporary db.

func (*Dbs) Get

func (t *Dbs) Get(ver uint64) interface{}

Get returns related object (tables) of temporary db.

Jump to

Keyboard shortcuts

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