statedb

package
v0.0.0-...-f94ef0f Latest Latest
Warning

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

Go to latest
Published: Aug 16, 2023 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type MemStore

type MemStore struct {
	*dao.Simple
	// contains filtered or unexported fields
}

type NativeContracts

type NativeContracts interface {
	Contracts() *native.Contracts
}

type StateDB

type StateDB struct {
	Err error
	// contains filtered or unexported fields
}

func NewStateDB

func NewStateDB(ps *dao.Simple, bc NativeContracts) *StateDB

func (*StateDB) AddAddressToAccessList

func (s *StateDB) AddAddressToAccessList(addr common.Address)

func (*StateDB) AddBalance

func (s *StateDB) AddBalance(address common.Address, amount *big.Int)

func (*StateDB) AddLog

func (s *StateDB) AddLog(l *types.Log)

func (*StateDB) AddPreimage

func (s *StateDB) AddPreimage(hash common.Hash, preimage []byte)

func (*StateDB) AddRefund

func (s *StateDB) AddRefund(amount uint64)

func (*StateDB) AddSlotToAccessList

func (s *StateDB) AddSlotToAccessList(addr common.Address, slot common.Hash)

func (*StateDB) AddressInAccessList

func (s *StateDB) AddressInAccessList(addr common.Address) bool

func (*StateDB) Commit

func (s *StateDB) Commit() error

func (*StateDB) CreateAccount

func (s *StateDB) CreateAccount(common.Address)

func (*StateDB) CurrentStore

func (s *StateDB) CurrentStore() *MemStore

func (*StateDB) Empty

func (s *StateDB) Empty(address common.Address) bool

func (*StateDB) Exist

func (s *StateDB) Exist(address common.Address) bool

func (*StateDB) ForEachStorage

func (s *StateDB) ForEachStorage(addr common.Address, cb func(common.Hash, common.Hash) bool) error

func (*StateDB) GetBalance

func (s *StateDB) GetBalance(address common.Address) *big.Int

func (*StateDB) GetCode

func (s *StateDB) GetCode(address common.Address) []byte

func (*StateDB) GetCodeHash

func (s *StateDB) GetCodeHash(address common.Address) common.Hash

func (*StateDB) GetCodeSize

func (s *StateDB) GetCodeSize(address common.Address) int

func (*StateDB) GetCommittedState

func (s *StateDB) GetCommittedState(address common.Address, key common.Hash) common.Hash

func (*StateDB) GetLogs

func (s *StateDB) GetLogs() []*types.Log

func (*StateDB) GetNonce

func (s *StateDB) GetNonce(address common.Address) uint64

func (*StateDB) GetRefund

func (s *StateDB) GetRefund() uint64

func (*StateDB) GetState

func (s *StateDB) GetState(address common.Address, key common.Hash) common.Hash

func (*StateDB) HasSuicided

func (s *StateDB) HasSuicided(address common.Address) bool

func (*StateDB) PrepareAccessList

func (s *StateDB) PrepareAccessList(sender common.Address, dest *common.Address, precompiles []common.Address, list types.AccessList)

func (*StateDB) RevertToSnapshot

func (s *StateDB) RevertToSnapshot(revid int)

func (*StateDB) SetCode

func (s *StateDB) SetCode(address common.Address, code []byte)

func (*StateDB) SetNonce

func (s *StateDB) SetNonce(address common.Address, nonce uint64)

func (*StateDB) SetState

func (s *StateDB) SetState(address common.Address, key common.Hash, value common.Hash)

func (*StateDB) SlotInAccessList

func (s *StateDB) SlotInAccessList(addr common.Address, slot common.Hash) (addressOk bool, slotOk bool)

func (*StateDB) Snapshot

func (s *StateDB) Snapshot() int

func (*StateDB) SubBalance

func (s *StateDB) SubBalance(address common.Address, amount *big.Int)

func (*StateDB) SubRefund

func (s *StateDB) SubRefund(amount uint64)

func (*StateDB) Suicide

func (s *StateDB) Suicide(address common.Address) bool

Jump to

Keyboard shortcuts

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