Documentation ¶
Index ¶
- Variables
- type ContractStore
- type VMCache
- type VMContext
- func (v *VMContext) CalculateAmount(block *types.StateBlock) (types.Balance, error)
- func (v *VMContext) GetAccountMeta(address types.Address) (*types.AccountMeta, error)
- func (v *VMContext) GetStorage(prefix, key []byte) ([]byte, error)
- func (v *VMContext) IsUserAccount(address types.Address) (bool, error)
- func (v *VMContext) Iterator(prefix []byte, fn func(key []byte, value []byte) error) error
- func (v *VMContext) SaveStorage() error
- func (v *VMContext) SaveTrie() error
- func (v *VMContext) SetStorage(prefix, key []byte, value []byte) error
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrStorageExists = errors.New("storage already exists") ErrStorageNotFound = errors.New("storage not found") )
Functions ¶
This section is empty.
Types ¶
type ContractStore ¶
type ContractStore interface { GetStorage(prefix, key []byte) ([]byte, error) SetStorage(prefix, key []byte, value []byte) error Iterator(prefix []byte, fn func(key []byte, value []byte) error) error CalculateAmount(block *types.StateBlock) (types.Balance, error) IsUserAccount(address types.Address) (bool, error) GetAccountMeta(address types.Address) (*types.AccountMeta, error) SaveStorage() error }
type VMCache ¶
type VMCache struct {
// contains filtered or unexported fields
}
func NewVMCache ¶
func (*VMCache) GetStorage ¶
func (*VMCache) SetStorage ¶
type VMContext ¶
type VMContext struct { Cache *VMCache // contains filtered or unexported fields }
func NewVMContext ¶
func (*VMContext) CalculateAmount ¶
func (*VMContext) GetAccountMeta ¶
func (*VMContext) IsUserAccount ¶
func (*VMContext) SaveStorage ¶
Click to show internal directories.
Click to hide internal directories.