Documentation ¶
Index ¶
- func GenesisExecuteContractCmd(defaultNodeHome string, genesisMutator GenesisMutator) *cobra.Command
- func GenesisInstantiateContractCmd(defaultNodeHome string, genesisMutator GenesisMutator) *cobra.Command
- func GenesisListCodesCmd(defaultNodeHome string, genReader GenesisReader) *cobra.Command
- func GenesisListContractsCmd(defaultNodeHome string, genReader GenesisReader) *cobra.Command
- func GenesisStoreCodeCmd(defaultNodeHome string, genesisMutator GenesisMutator) *cobra.Command
- func GetCmdExtraProposal(cdcP *codec.CodecProxy, reg interfacetypes.InterfaceRegistry) *cobra.Command
- func NewCmdGetAddressWhitelist(m *codec.CodecProxy, reg codectypes.InterfaceRegistry) *cobra.Command
- func NewCmdGetContractHistory(m *codec.CodecProxy, reg codectypes.InterfaceRegistry) *cobra.Command
- func NewCmdGetContractInfo(m *codec.CodecProxy, reg codectypes.InterfaceRegistry) *cobra.Command
- func NewCmdGetContractState(m *codec.CodecProxy, reg codectypes.InterfaceRegistry) *cobra.Command
- func NewCmdGetExtraParams(m *codec.CodecProxy, reg codectypes.InterfaceRegistry) *cobra.Command
- func NewCmdGetParams(m *codec.CodecProxy, reg codectypes.InterfaceRegistry) *cobra.Command
- func NewCmdLibVersion(m *codec.CodecProxy, reg codectypes.InterfaceRegistry) *cobra.Command
- func NewCmdListCode(m *codec.CodecProxy, reg codectypes.InterfaceRegistry) *cobra.Command
- func NewCmdListContractBlockedMethod(m *codec.CodecProxy) *cobra.Command
- func NewCmdListContractByCode(m *codec.CodecProxy, reg codectypes.InterfaceRegistry) *cobra.Command
- func NewCmdListPinnedCode(m *codec.CodecProxy, reg codectypes.InterfaceRegistry) *cobra.Command
- func NewCmdQueryCode(m *codec.CodecProxy, reg codectypes.InterfaceRegistry) *cobra.Command
- func NewCmdQueryCodeInfo(m *codec.CodecProxy, reg codectypes.InterfaceRegistry) *cobra.Command
- func NewExecuteContractCmd(m *codec.CodecProxy, reg codectypes.InterfaceRegistry) *cobra.Command
- func NewInstantiateContractCmd(m *codec.CodecProxy, reg codectypes.InterfaceRegistry) *cobra.Command
- func NewMigrateContractCmd(m *codec.CodecProxy, reg codectypes.InterfaceRegistry) *cobra.Command
- func NewQueryCmd(cdc *codec.CodecProxy, reg codectypes.InterfaceRegistry) *cobra.Command
- func NewStoreCodeCmd(m *codec.CodecProxy, reg codectypes.InterfaceRegistry) *cobra.Command
- func NewTxCmd(cdc *codec.CodecProxy, reg codectypes.InterfaceRegistry) *cobra.Command
- func NewUpdateContractAdminCmd(m *codec.CodecProxy, reg codectypes.InterfaceRegistry) *cobra.Command
- func ProposalMigrateContractCmd(m *codec.CodecProxy, reg codectypes.InterfaceRegistry) *cobra.Command
- func ProposalPinCodesCmd(m *codec.CodecProxy, reg codectypes.InterfaceRegistry) *cobra.Command
- func ProposalUnpinCodesCmd(m *codec.CodecProxy, reg codectypes.InterfaceRegistry) *cobra.Command
- func ProposalUpdateContractAdminCmd(m *codec.CodecProxy, reg codectypes.InterfaceRegistry) *cobra.Command
- func ProposalUpdateDeploymentWhitelistCmd(cdcP *codec.CodecProxy, reg interfacetypes.InterfaceRegistry) *cobra.Command
- func ProposalUpdateWASMContractMethodBlockedListCmd(cdcP *codec.CodecProxy, reg interfacetypes.InterfaceRegistry) *cobra.Command
- type CodeMeta
- type ContractMeta
- type DefaultGenesisIO
- type DefaultGenesisReader
- type GenesisData
- type GenesisMutator
- type GenesisReader
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GenesisExecuteContractCmd ¶
func GenesisExecuteContractCmd(defaultNodeHome string, genesisMutator GenesisMutator) *cobra.Command
GenesisExecuteContractCmd cli command to add a `MsgExecuteContract` to the wasm section of the genesis that is executed on block 0.
func GenesisInstantiateContractCmd ¶
func GenesisInstantiateContractCmd(defaultNodeHome string, genesisMutator GenesisMutator) *cobra.Command
GenesisInstantiateContractCmd cli command to add a `MsgInstantiateContract` to the wasm section of the genesis that is executed on block 0.
func GenesisListCodesCmd ¶
func GenesisListCodesCmd(defaultNodeHome string, genReader GenesisReader) *cobra.Command
GenesisListCodesCmd cli command to list all codes stored in the genesis wasm.code section as well as from messages that are queued in the wasm.genMsgs section.
func GenesisListContractsCmd ¶
func GenesisListContractsCmd(defaultNodeHome string, genReader GenesisReader) *cobra.Command
GenesisListContractsCmd cli command to list all contracts stored in the genesis wasm.contract section as well as from messages that are queued in the wasm.genMsgs section.
func GenesisStoreCodeCmd ¶
func GenesisStoreCodeCmd(defaultNodeHome string, genesisMutator GenesisMutator) *cobra.Command
GenesisStoreCodeCmd cli command to add a `MsgStoreCode` to the wasm section of the genesis that is executed on block 0.
func GetCmdExtraProposal ¶ added in v1.7.0
func GetCmdExtraProposal(cdcP *codec.CodecProxy, reg interfacetypes.InterfaceRegistry) *cobra.Command
GetCmdExtraProposal implements a command handler for submitting extra proposal transaction
func NewCmdGetAddressWhitelist ¶ added in v1.6.6
func NewCmdGetAddressWhitelist(m *codec.CodecProxy, reg codectypes.InterfaceRegistry) *cobra.Command
func NewCmdGetContractHistory ¶
func NewCmdGetContractHistory(m *codec.CodecProxy, reg codectypes.InterfaceRegistry) *cobra.Command
NewCmdGetContractHistory prints the code history for a given contract
func NewCmdGetContractInfo ¶
func NewCmdGetContractInfo(m *codec.CodecProxy, reg codectypes.InterfaceRegistry) *cobra.Command
NewCmdGetContractInfo gets details about a given contract
func NewCmdGetContractState ¶
func NewCmdGetContractState(m *codec.CodecProxy, reg codectypes.InterfaceRegistry) *cobra.Command
NewCmdGetContractState dumps full internal state of a given contract
func NewCmdGetExtraParams ¶ added in v1.7.0
func NewCmdGetExtraParams(m *codec.CodecProxy, reg codectypes.InterfaceRegistry) *cobra.Command
func NewCmdGetParams ¶ added in v1.6.6
func NewCmdGetParams(m *codec.CodecProxy, reg codectypes.InterfaceRegistry) *cobra.Command
func NewCmdLibVersion ¶ added in v1.6.6
func NewCmdLibVersion(m *codec.CodecProxy, reg codectypes.InterfaceRegistry) *cobra.Command
NewCmdLibVersion gets current libwasmvm version.
func NewCmdListCode ¶
func NewCmdListCode(m *codec.CodecProxy, reg codectypes.InterfaceRegistry) *cobra.Command
NewCmdListCode lists all wasm code uploaded
func NewCmdListContractBlockedMethod ¶ added in v1.6.6
func NewCmdListContractBlockedMethod(m *codec.CodecProxy) *cobra.Command
func NewCmdListContractByCode ¶
func NewCmdListContractByCode(m *codec.CodecProxy, reg codectypes.InterfaceRegistry) *cobra.Command
NewCmdListContractByCode lists all wasm code uploaded for given code id
func NewCmdListPinnedCode ¶
func NewCmdListPinnedCode(m *codec.CodecProxy, reg codectypes.InterfaceRegistry) *cobra.Command
NewCmdListPinnedCode lists all wasm code ids that are pinned
func NewCmdQueryCode ¶
func NewCmdQueryCode(m *codec.CodecProxy, reg codectypes.InterfaceRegistry) *cobra.Command
NewCmdQueryCode returns the bytecode for a given contract
func NewCmdQueryCodeInfo ¶ added in v1.6.6
func NewCmdQueryCodeInfo(m *codec.CodecProxy, reg codectypes.InterfaceRegistry) *cobra.Command
NewCmdQueryCodeInfo returns the code info for a given code id
func NewExecuteContractCmd ¶
func NewExecuteContractCmd(m *codec.CodecProxy, reg codectypes.InterfaceRegistry) *cobra.Command
func NewInstantiateContractCmd ¶
func NewInstantiateContractCmd(m *codec.CodecProxy, reg codectypes.InterfaceRegistry) *cobra.Command
func NewMigrateContractCmd ¶
func NewMigrateContractCmd(m *codec.CodecProxy, reg codectypes.InterfaceRegistry) *cobra.Command
func NewQueryCmd ¶
func NewQueryCmd(cdc *codec.CodecProxy, reg codectypes.InterfaceRegistry) *cobra.Command
NewQueryCmd returns the query commands for wasm
func NewStoreCodeCmd ¶
func NewStoreCodeCmd(m *codec.CodecProxy, reg codectypes.InterfaceRegistry) *cobra.Command
func NewTxCmd ¶
func NewTxCmd(cdc *codec.CodecProxy, reg codectypes.InterfaceRegistry) *cobra.Command
NewTxCmd returns the transaction commands for wasm
func NewUpdateContractAdminCmd ¶
func NewUpdateContractAdminCmd(m *codec.CodecProxy, reg codectypes.InterfaceRegistry) *cobra.Command
func ProposalMigrateContractCmd ¶ added in v1.6.4
func ProposalMigrateContractCmd(m *codec.CodecProxy, reg codectypes.InterfaceRegistry) *cobra.Command
func ProposalPinCodesCmd ¶ added in v1.6.6
func ProposalPinCodesCmd(m *codec.CodecProxy, reg codectypes.InterfaceRegistry) *cobra.Command
func ProposalUnpinCodesCmd ¶ added in v1.6.6
func ProposalUnpinCodesCmd(m *codec.CodecProxy, reg codectypes.InterfaceRegistry) *cobra.Command
func ProposalUpdateContractAdminCmd ¶ added in v1.6.4
func ProposalUpdateContractAdminCmd(m *codec.CodecProxy, reg codectypes.InterfaceRegistry) *cobra.Command
func ProposalUpdateDeploymentWhitelistCmd ¶ added in v1.6.4
func ProposalUpdateDeploymentWhitelistCmd(cdcP *codec.CodecProxy, reg interfacetypes.InterfaceRegistry) *cobra.Command
func ProposalUpdateWASMContractMethodBlockedListCmd ¶ added in v1.6.4
func ProposalUpdateWASMContractMethodBlockedListCmd(cdcP *codec.CodecProxy, reg interfacetypes.InterfaceRegistry) *cobra.Command
Types ¶
type CodeMeta ¶
func GetAllCodes ¶
func GetAllCodes(state *types.GenesisState) ([]CodeMeta, error)
type ContractMeta ¶
type ContractMeta struct { ContractAddress string `json:"contract_address"` Info types.ContractInfo `json:"info"` }
func GetAllContracts ¶
func GetAllContracts(state *types.GenesisState) []ContractMeta
type DefaultGenesisIO ¶
type DefaultGenesisIO struct {
DefaultGenesisReader
}
DefaultGenesisIO implements both interfaces to read and modify the genesis state for this module. This implementation uses the default data structure that is used by the module.go genesis import/ export.
func NewDefaultGenesisIO ¶
func NewDefaultGenesisIO() *DefaultGenesisIO
NewDefaultGenesisIO constructor to create a new instance
func (DefaultGenesisIO) AlterWasmModuleState ¶
func (x DefaultGenesisIO) AlterWasmModuleState(cmd *cobra.Command, callback func(state *types.GenesisState, appState map[string]json.RawMessage) error) error
AlterWasmModuleState loads the genesis from the default or set home dir, unmarshalls the wasm module section into the object representation calls the callback function to modify it and marshals the modified state back into the genesis file
type DefaultGenesisReader ¶
type DefaultGenesisReader struct{}
func (DefaultGenesisReader) ReadWasmGenesis ¶
func (d DefaultGenesisReader) ReadWasmGenesis(cmd *cobra.Command) (*GenesisData, error)
type GenesisData ¶
type GenesisData struct { GenesisFile string GenDoc *tmtypes.GenesisDoc AppState map[string]json.RawMessage WasmModuleState *types.GenesisState }
GenesisData contains raw and unmarshalled data from the genesis file
func NewGenesisData ¶
func NewGenesisData(genesisFile string, genDoc *tmtypes.GenesisDoc, appState map[string]json.RawMessage, wasmModuleState *types.GenesisState) *GenesisData
type GenesisMutator ¶
type GenesisMutator interface { // AlterWasmModuleState loads the genesis from the default or set home dir, // unmarshalls the wasm module section into the object representation // calls the callback function to modify it // and marshals the modified state back into the genesis file AlterWasmModuleState(cmd *cobra.Command, callback func(state *types.GenesisState, appState map[string]json.RawMessage) error) error }
GenesisMutator extension point to modify the wasm module genesis state. This gives flexibility to customize the data structure in the genesis file a bit.
type GenesisReader ¶
type GenesisReader interface {
ReadWasmGenesis(cmd *cobra.Command) (*GenesisData, error)
}
GenesisReader reads genesis data. Extension point for custom genesis state readers.