Struct abstract_app::traits::AccountRegistry
source · pub struct AccountRegistry<'a, T>where
T: AccountVerification,{ /* private fields */ }Expand description
API for querying and verifying a sender’s identity in the context of Abstract Accounts.
§Example
use abstract_sdk::prelude::*;
let acc_registry: AccountRegistry<MockModule> = module.account_registry(deps.as_ref()).unwrap();Implementations§
source§impl<'a, T> AccountRegistry<'a, T>where
T: AccountVerification,
impl<'a, T> AccountRegistry<'a, T>where
T: AccountVerification,
sourcepub fn assert_manager(
&self,
maybe_manager: &Addr
) -> Result<AccountBase, AbstractSdkError>
pub fn assert_manager( &self, maybe_manager: &Addr ) -> Result<AccountBase, AbstractSdkError>
Verify if the provided manager address is indeed a user.
sourcepub fn assert_proxy(
&self,
maybe_proxy: &Addr
) -> Result<AccountBase, AbstractSdkError>
pub fn assert_proxy( &self, maybe_proxy: &Addr ) -> Result<AccountBase, AbstractSdkError>
Verify if the provided proxy address is indeed a user.
sourcepub fn proxy_address(
&self,
account_id: &AccountId
) -> Result<Addr, AbstractSdkError>
pub fn proxy_address( &self, account_id: &AccountId ) -> Result<Addr, AbstractSdkError>
Get the proxy address for a given account id.
sourcepub fn manager_address(
&self,
account_id: &AccountId
) -> Result<Addr, AbstractSdkError>
pub fn manager_address( &self, account_id: &AccountId ) -> Result<Addr, AbstractSdkError>
Get the manager address for a given account id.
sourcepub fn account_base(
&self,
account_id: &AccountId
) -> Result<AccountBase, AbstractSdkError>
pub fn account_base( &self, account_id: &AccountId ) -> Result<AccountBase, AbstractSdkError>
Get the account base for a given account id.
sourcepub fn account_id(
&self,
maybe_core_contract_addr: &Addr
) -> Result<AccountId, AbstractSdkError>
pub fn account_id( &self, maybe_core_contract_addr: &Addr ) -> Result<AccountId, AbstractSdkError>
Get AccountId for given manager or proxy address.
sourcepub fn namespace_registration_fee(
&self
) -> Result<Option<Coin>, AbstractSdkError>
pub fn namespace_registration_fee( &self ) -> Result<Option<Coin>, AbstractSdkError>
Get namespace registration fee
Trait Implementations§
source§impl<'a, T> Clone for AccountRegistry<'a, T>where
T: Clone + AccountVerification,
impl<'a, T> Clone for AccountRegistry<'a, T>where
T: Clone + AccountVerification,
source§fn clone(&self) -> AccountRegistry<'a, T>
fn clone(&self) -> AccountRegistry<'a, T>
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl<'a, T> Freeze for AccountRegistry<'a, T>
impl<'a, T> !RefUnwindSafe for AccountRegistry<'a, T>
impl<'a, T> !Send for AccountRegistry<'a, T>
impl<'a, T> !Sync for AccountRegistry<'a, T>
impl<'a, T> Unpin for AccountRegistry<'a, T>
impl<'a, T> !UnwindSafe for AccountRegistry<'a, T>
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> Instrument for T
impl<T> Instrument for T
source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
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 moresource§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
Wrap the input message
T in a tonic::Request