pub struct KujiraQuerier<'a> { /* private fields */ }
Expand description
This is a helper wrapper to easily use our custom queries
Implementations§
Source§impl<'a> KujiraQuerier<'a>
impl<'a> KujiraQuerier<'a>
pub fn new(querier: &'a QuerierWrapper<'a, KujiraQuery>) -> Self
Sourcepub fn query_exchange_rate<T: Into<String>>(
&self,
denom: T,
) -> StdResult<HumanPrice>
pub fn query_exchange_rate<T: Into<String>>( &self, denom: T, ) -> StdResult<HumanPrice>
Queries the oracle module for the exchange rate of the specified denom.
This returns a HumanPrice
, which is a wrapper around Decimal
that
should be normalized before use in calculations.
pub fn query_supply_of(&self, denom: Denom) -> StdResult<SupplyResponse>
pub fn inner(&self) -> &QuerierWrapper<'a, KujiraQuery>
pub fn query_interchain_address( &self, owner: Addr, connection_id: String, account_id: String, ) -> StdResult<AccountAddressResponse>
pub fn query_verify_membership( &self, connection: String, revision_number: u64, revision_height: u64, proof: Binary, value: Binary, path_prefix: String, path_key: Binary, ) -> StdResult<IbcVerifyResponse>
pub fn query_verify_non_membership( &self, connection: String, revision_number: u64, revision_height: u64, proof: Binary, path_prefix: String, path_key: Binary, ) -> StdResult<IbcVerifyResponse>
Trait Implementations§
Source§impl<'a> From<&'a Deps<'a, KujiraQuery>> for KujiraQuerier<'a>
impl<'a> From<&'a Deps<'a, KujiraQuery>> for KujiraQuerier<'a>
Source§fn from(deps: &'a Deps<'_, KujiraQuery>) -> Self
fn from(deps: &'a Deps<'_, KujiraQuery>) -> Self
Converts to this type from the input type.
Source§impl<'a> From<&'a DepsMut<'a, KujiraQuery>> for KujiraQuerier<'a>
impl<'a> From<&'a DepsMut<'a, KujiraQuery>> for KujiraQuerier<'a>
Source§fn from(deps: &'a DepsMut<'_, KujiraQuery>) -> Self
fn from(deps: &'a DepsMut<'_, KujiraQuery>) -> Self
Converts to this type from the input type.
Source§impl<'a> From<&'a QuerierWrapper<'a, KujiraQuery>> for KujiraQuerier<'a>
impl<'a> From<&'a QuerierWrapper<'a, KujiraQuery>> for KujiraQuerier<'a>
Source§fn from(querier: &'a QuerierWrapper<'_, KujiraQuery>) -> Self
fn from(querier: &'a QuerierWrapper<'_, KujiraQuery>) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl<'a> Freeze for KujiraQuerier<'a>
impl<'a> !RefUnwindSafe for KujiraQuerier<'a>
impl<'a> !Send for KujiraQuerier<'a>
impl<'a> !Sync for KujiraQuerier<'a>
impl<'a> Unpin for KujiraQuerier<'a>
impl<'a> !UnwindSafe for KujiraQuerier<'a>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more