statestore

package
v0.0.0-...-c8e9c26 Latest Latest
Warning

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

Go to latest
Published: Mar 30, 2018 License: LGPL-3.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type MemoryStore

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

func NewMemDatabase

func NewMemDatabase() *MemoryStore

func (*MemoryStore) Change

func (db *MemoryStore) Change(prefix byte, key []byte, trie bool)

func (*MemoryStore) Delete

func (db *MemoryStore) Delete(prefix byte, key []byte)

func (*MemoryStore) Get

func (db *MemoryStore) Get(prefix byte, key []byte) *common.StateItem

func (*MemoryStore) GetChangeSet

func (db *MemoryStore) GetChangeSet() map[string]*common.StateItem

func (*MemoryStore) Put

func (db *MemoryStore) Put(prefix byte, key []byte, value states.StateValue, state common.ItemState, trie bool)

type StateBatch

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

func NewStateStoreBatch

func NewStateStoreBatch(memoryStore common.MemoryCacheStore, store common.PersistStore) *StateBatch

func (*StateBatch) Change

func (this *StateBatch) Change(prefix byte, key []byte, trie bool)

func (*StateBatch) CommitTo

func (self *StateBatch) CommitTo() error

func (*StateBatch) Find

func (self *StateBatch) Find(prefix common.DataEntryPrefix, key []byte) ([]*common.StateItem, error)

func (*StateBatch) TryAdd

func (self *StateBatch) TryAdd(prefix common.DataEntryPrefix, key []byte, value states.StateValue, trie bool)

func (*StateBatch) TryDelete

func (self *StateBatch) TryDelete(prefix common.DataEntryPrefix, key []byte)

func (*StateBatch) TryGet

func (self *StateBatch) TryGet(prefix common.DataEntryPrefix, key []byte) (*common.StateItem, error)

func (*StateBatch) TryGetAndChange

func (self *StateBatch) TryGetAndChange(prefix common.DataEntryPrefix, key []byte, trie bool) (states.StateValue, error)

func (*StateBatch) TryGetOrAdd

func (self *StateBatch) TryGetOrAdd(prefix common.DataEntryPrefix, key []byte, value states.StateValue, trie bool) error

Jump to

Keyboard shortcuts

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