mem

package
v0.46.4 Latest Latest
Warning

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

Go to latest
Published: Apr 4, 2022 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Store

type Store struct {
	dbadapter.Store
	// contains filtered or unexported fields
}

Store implements an in-memory only KVStore. Entries are persisted between commits and thus between blocks. State in Memory store is not committed as part of app state but maintained privately by each node

func NewStore

func NewStore() *Store

NewStore constructs a new in-memory store.

func (*Store) Commit

func (s *Store) Commit() (id types.CommitID)

Commit commits to the underlying DB.

func (*Store) GetPruning

func (s *Store) GetPruning() types.PruningOptions

func (Store) GetStoreType

func (s Store) GetStoreType() types.StoreType

GetStoreType returns the Store's type.

func (Store) LastCommitID

func (s Store) LastCommitID() (id types.CommitID)

func (*Store) SetPruning

func (s *Store) SetPruning(pruning types.PruningOptions)

Jump to

Keyboard shortcuts

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