Enum tg_bindings::GovProposal
source · [−]pub enum GovProposal {
Show 13 variants
Text {},
RegisterUpgrade {
name: String,
height: u64,
info: String,
},
CancelUpgrade {},
ChangeParams(Vec<ParamChange>),
IbcClientUpdate {
client_id: String,
header: ProtoAny,
},
PromoteToPrivilegedContract {
contract: String,
},
DemotePrivilegedContract {
contract: String,
},
InstantiateContract {
run_as: String,
admin: String,
code_id: u64,
label: String,
init_msg: Binary,
funds: Vec<Coin>,
},
MigrateContract {
run_as: String,
contract: String,
code_id: u64,
migrate_msg: Binary,
},
SetContractAdmin {
contract: String,
new_admin: String,
},
ClearContractAdmin {
contract: String,
},
PinCodes {
code_ids: Vec<u64>,
},
UnpinCodes {
code_ids: Vec<u64>,
},
}Variants
Text
Fields
Signaling proposal, the text and description field will be recorded
RegisterUpgrade
Fields
name: StringSets the name for the upgrade. This name will be used by the upgraded version of the software to apply any special “on-upgrade” commands during the first BeginBlock method after the upgrade is applied.
height: u64The height at which the upgrade must be performed. (Time-based upgrades are not supported due to instability)
info: StringAny application specific upgrade info to be included on-chain such as a git commit that validators could automatically upgrade to
Register an “live upgrade” on the x/upgrade module See https://github.com/cosmos/cosmos-sdk/blob/v0.42.3/proto/cosmos/upgrade/v1beta1/upgrade.proto#L12-L53
CancelUpgrade
Fields
There can only be one pending upgrade at a given time. This cancels the pending upgrade, if any. See https://github.com/cosmos/cosmos-sdk/blob/v0.42.3/proto/cosmos/upgrade/v1beta1/upgrade.proto#L57-L62
ChangeParams(Vec<ParamChange>)
Defines a proposal to change one or more parameters. See https://github.com/cosmos/cosmos-sdk/blob/v0.42.3/proto/cosmos/params/v1beta1/params.proto#L9-L27
IbcClientUpdate
Updates the matching client to set a new trusted header. This can be used by governance to restore a client that has timed out or forked or otherwise broken. See https://github.com/cosmos/cosmos-sdk/blob/v0.42.3/proto/ibc/core/client/v1/client.proto#L36-L49
PromoteToPrivilegedContract
Fields
contract: StringSee https://github.com/confio/tgrade/blob/privileged_contracts_5/proto/confio/twasm/v1beta1/proposal.proto
DemotePrivilegedContract
Fields
contract: StringSee https://github.com/confio/tgrade/blob/privileged_contracts_5/proto/confio/twasm/v1beta1/proposal.proto
InstantiateContract
Fields
run_as: Stringthe address that is passed to the contract’s environment as sender
admin: StringAdmin is an optional address that can execute migrations
code_id: u64the reference to the stored WASM code
label: Stringmetadata to be stored with a contract instance.
init_msg: Binaryjson encoded message to be passed to the contract on instantiation
See https://github.com/CosmWasm/wasmd/blob/master/proto/cosmwasm/wasm/v1beta1/proposal.proto#L32-L54
MigrateContract
Fields
run_as: Stringthe address that is passed to the contract’s environment as sender
contract: Stringthe contract address to be migrated
code_id: u64a reference to the new WASM code that it should be migrated to
migrate_msg: Binaryjson encoded message to be passed to the new WASM code to perform the migration
See https://github.com/CosmWasm/wasmd/blob/master/proto/cosmwasm/wasm/v1beta1/proposal.proto#L56-L70
SetContractAdmin
Fields
contract: Stringthe contract address to be updated
new_admin: Stringthe account address to become admin of this contract
See https://github.com/CosmWasm/wasmd/blob/master/proto/cosmwasm/wasm/v1beta1/proposal.proto#L72-L82
ClearContractAdmin
Fields
contract: Stringthe contract address to be cleared
See https://github.com/CosmWasm/wasmd/blob/master/proto/cosmwasm/wasm/v1beta1/proposal.proto#L84-L93
PinCodes
See https://github.com/CosmWasm/wasmd/blob/master/proto/cosmwasm/wasm/v1beta1/proposal.proto#L95-L107
UnpinCodes
See https://github.com/CosmWasm/wasmd/blob/master/proto/cosmwasm/wasm/v1beta1/proposal.proto#L109-L121
Trait Implementations
sourceimpl Clone for GovProposal
impl Clone for GovProposal
sourcefn clone(&self) -> GovProposal
fn clone(&self) -> GovProposal
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read more
sourceimpl Debug for GovProposal
impl Debug for GovProposal
sourceimpl<'de> Deserialize<'de> for GovProposal
impl<'de> Deserialize<'de> for GovProposal
sourcefn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
sourceimpl JsonSchema for GovProposal
impl JsonSchema for GovProposal
sourcefn schema_name() -> String
fn schema_name() -> String
The name of the generated JSON Schema. Read more
sourcefn json_schema(gen: &mut SchemaGenerator) -> Schema
fn json_schema(gen: &mut SchemaGenerator) -> Schema
Generates a JSON Schema for this type. Read more
sourcefn is_referenceable() -> bool
fn is_referenceable() -> bool
Whether JSON Schemas generated for this type should be re-used where possible using the $ref keyword. Read more
sourceimpl PartialEq<GovProposal> for GovProposal
impl PartialEq<GovProposal> for GovProposal
sourcefn eq(&self, other: &GovProposal) -> bool
fn eq(&self, other: &GovProposal) -> bool
This method tests for self and other values to be equal, and is used
by ==. Read more
sourcefn ne(&self, other: &GovProposal) -> bool
fn ne(&self, other: &GovProposal) -> bool
This method tests for !=.
sourceimpl Serialize for GovProposal
impl Serialize for GovProposal
impl StructuralPartialEq for GovProposal
Auto Trait Implementations
impl RefUnwindSafe for GovProposal
impl Send for GovProposal
impl Sync for GovProposal
impl Unpin for GovProposal
impl UnwindSafe for GovProposal
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcefn clone_into(&self, target: &mut T)
fn clone_into(&self, target: &mut T)
toowned_clone_into)Uses borrowed data to replace owned data, usually by cloning. Read more