Documentation ¶
Overview ¶
DONTCOVER nolint
Index ¶
Constants ¶
View Source
const (
ModuleName = "wasm"
)
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CodeInfo ¶
type CodeInfo struct { CodeID uint64 `json:"code_id"` CodeHash []byte `json:"code_hash"` Creator sdk.AccAddress `json:"creator"` }
CodeInfo is data for the uploaded contract WASM code
type Contract ¶
type Contract struct { ContractInfo ContractInfo `json:"contract_info"` ContractStore []Model `json:"contract_store"` }
Contract struct encompasses ContractAddress, ContractInfo, and ContractState
type ContractInfo ¶
type ContractInfo struct { Address sdk.AccAddress `json:"address"` Owner sdk.AccAddress `json:"owner"` CodeID uint64 `json:"code_id"` InitMsg []byte `json:"init_msg"` Migratable bool `json:"migratable"` }
ContractInfo stores a WASM contract instance
type GenesisState ¶
type GenesisState struct { Params Params `json:"params" yaml:"params"` LastCodeID uint64 `json:"last_code_id" yaml:"last_code_id"` LastInstanceID uint64 `json:"last_instance_id" yaml:"last_instance_id"` Codes []Code `json:"codes" yaml:"codes"` Contracts []Contract `json:"contracts" yaml:"contracts"` }
GenesisState is the struct representation of the export genesis
func NewGenesisState ¶
func NewGenesisState(params Params, lastCodeID, lastInstanceID uint64, codes []Code, contracts []Contract) GenesisState
NewGenesisState creates a new GenesisState object
type Params ¶
type Params struct { MaxContractSize uint64 `json:"max_contract_size" yaml:"max_contract_size"` // allowed max contract bytes size MaxContractGas uint64 `json:"max_contract_gas" yaml:"max_contract_gas"` // allowed max gas usages per each contract execution MaxContractMsgSize uint64 `json:"max_contract_msg_size" yaml:"max_contract_msg_size"` // allowed max contract exe msg bytes size }
Params wasm parameters
Click to show internal directories.
Click to hide internal directories.