QueryMsgFns

Trait QueryMsgFns 

Source
pub trait QueryMsgFns<Chain: QueryHandler + ChainState, CwOrchQueryMsgType>: CwOrchQuery<Chain, QueryMsg = CwOrchQueryMsgType>
where QueryMsg: Into<CwOrchQueryMsgType>,
{ // Provided methods fn threshold(&self) -> Result<ThresholdResponse, CwEnvError> { ... } fn proposal(&self, proposal_id: u64) -> Result<ProposalResponse, CwEnvError> { ... } fn list_proposals( &self, limit: Option<u32>, start_after: Option<u64>, ) -> Result<ProposalListResponse, CwEnvError> { ... } fn reverse_proposals( &self, limit: Option<u32>, start_before: Option<u64>, ) -> Result<ProposalListResponse, CwEnvError> { ... } fn vote( &self, proposal_id: u64, voter: impl Into<String>, ) -> Result<VoteResponse, CwEnvError> { ... } fn list_votes( &self, proposal_id: u64, limit: Option<u32>, start_after: Option<String>, ) -> Result<VoteListResponse, CwEnvError> { ... } fn voter( &self, address: impl Into<String>, ) -> Result<VoterResponse, CwEnvError> { ... } fn list_voters( &self, limit: Option<u32>, start_after: Option<String>, ) -> Result<VoterListResponse, CwEnvError> { ... } fn config(&self) -> Result<Config, CwEnvError> { ... } }
Expand description

Automatically derived trait that allows you to call the variants of the message directly without the need to construct the struct yourself.

Provided Methods§

Source

fn threshold(&self) -> Result<ThresholdResponse, CwEnvError>

Automatically generated wrapper around QueryMsg::Threshold variant

Source

fn proposal(&self, proposal_id: u64) -> Result<ProposalResponse, CwEnvError>

Automatically generated wrapper around QueryMsg::Proposal variant

Source

fn list_proposals( &self, limit: Option<u32>, start_after: Option<u64>, ) -> Result<ProposalListResponse, CwEnvError>

Automatically generated wrapper around QueryMsg::ListProposals variant

Source

fn reverse_proposals( &self, limit: Option<u32>, start_before: Option<u64>, ) -> Result<ProposalListResponse, CwEnvError>

Automatically generated wrapper around QueryMsg::ReverseProposals variant

Source

fn vote( &self, proposal_id: u64, voter: impl Into<String>, ) -> Result<VoteResponse, CwEnvError>

Automatically generated wrapper around QueryMsg::Vote variant

Source

fn list_votes( &self, proposal_id: u64, limit: Option<u32>, start_after: Option<String>, ) -> Result<VoteListResponse, CwEnvError>

Automatically generated wrapper around QueryMsg::ListVotes variant

Source

fn voter(&self, address: impl Into<String>) -> Result<VoterResponse, CwEnvError>

Automatically generated wrapper around QueryMsg::Voter variant

Source

fn list_voters( &self, limit: Option<u32>, start_after: Option<String>, ) -> Result<VoterListResponse, CwEnvError>

Automatically generated wrapper around QueryMsg::ListVoters variant

Source

fn config(&self) -> Result<Config, CwEnvError>

Automatically generated wrapper around QueryMsg::Config variant

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§

Source§

impl<Chain: QueryHandler + ChainState, CwOrchQueryMsgType, SupportedContract> QueryMsgFns<Chain, CwOrchQueryMsgType> for SupportedContract
where QueryMsg: Into<CwOrchQueryMsgType>, SupportedContract: CwOrchQuery<Chain, QueryMsg = CwOrchQueryMsgType>,

Available on non-WebAssembly only.