state

package
v0.6.2 Latest Latest
Warning

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

Go to latest
Published: Jul 28, 2017 License: Apache-2.0 Imports: 7 Imported by: 4

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ExecTx

func ExecTx(state *State, pgz *types.Plugins, tx types.Tx, isCheckTx bool, evc events.Fireable) abci.Result

If the tx is invalid, a TMSP error will be returned.

Types

type State

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

CONTRACT: State should be quick to copy. See CacheWrap().

func NewState

func NewState(store types.KVStore) *State

func (*State) CacheSync

func (s *State) CacheSync()

NOTE: errors if s is not from CacheWrap()

func (*State) CacheWrap

func (s *State) CacheWrap() *State

func (*State) Commit

func (s *State) Commit() abci.Result

func (*State) Get

func (s *State) Get(key []byte) (value []byte)

func (*State) GetAccount

func (s *State) GetAccount(addr []byte) *types.Account

func (*State) GetChainID

func (s *State) GetChainID() string

func (*State) Set

func (s *State) Set(key []byte, value []byte)

func (*State) SetAccount

func (s *State) SetAccount(addr []byte, acc *types.Account)

func (*State) SetChainID

func (s *State) SetChainID(chainID string)

func (*State) SetLogger added in v0.5.0

func (s *State) SetLogger(l log.Logger)

Jump to

Keyboard shortcuts

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