pub struct RegistryContract {
pub address: Addr,
}
Expand description
Store the Registry contract.
Implements [AbstractRegistryAccess
] (defined in abstract-sdk)
Fields§
§address: Addr
Address of the registry contract
Implementations§
Source§impl RegistryContract
impl RegistryContract
Sourcepub fn new(deps: Deps<'_>, abstract_code_id: u64) -> AbstractResult<Self>
pub fn new(deps: Deps<'_>, abstract_code_id: u64) -> AbstractResult<Self>
Retrieve address of the Registry
Sourcepub fn query_module_reference_raw(
&self,
module_info: &ModuleInfo,
querier: &QuerierWrapper<'_>,
) -> RegistryResult<ModuleReference>
pub fn query_module_reference_raw( &self, module_info: &ModuleInfo, querier: &QuerierWrapper<'_>, ) -> RegistryResult<ModuleReference>
Raw query for a module reference
Sourcepub fn query_module(
&self,
module_info: ModuleInfo,
querier: &QuerierWrapper<'_>,
) -> RegistryResult<Module>
pub fn query_module( &self, module_info: ModuleInfo, querier: &QuerierWrapper<'_>, ) -> RegistryResult<Module>
Smart query for a module
Sourcepub fn query_config(
&self,
module_info: ModuleInfo,
querier: &QuerierWrapper<'_>,
) -> RegistryResult<ModuleConfiguration>
pub fn query_config( &self, module_info: ModuleInfo, querier: &QuerierWrapper<'_>, ) -> RegistryResult<ModuleConfiguration>
Smart query for a module config
Sourcepub fn query_modules_configs(
&self,
infos: Vec<ModuleInfo>,
querier: &QuerierWrapper<'_>,
) -> RegistryResult<Vec<ModuleResponse>>
pub fn query_modules_configs( &self, infos: Vec<ModuleInfo>, querier: &QuerierWrapper<'_>, ) -> RegistryResult<Vec<ModuleResponse>>
Smart query for a modules and its configurations
Sourcepub fn query_namespace(
&self,
namespace: Namespace,
querier: &QuerierWrapper<'_>,
) -> RegistryResult<NamespaceResponse>
pub fn query_namespace( &self, namespace: Namespace, querier: &QuerierWrapper<'_>, ) -> RegistryResult<NamespaceResponse>
Queries the account that owns the namespace Is also returns the base modules of that account (Account)
Sourcepub fn query_namespace_raw(
&self,
namespace: Namespace,
querier: &QuerierWrapper<'_>,
) -> RegistryResult<Option<AccountId>>
pub fn query_namespace_raw( &self, namespace: Namespace, querier: &QuerierWrapper<'_>, ) -> RegistryResult<Option<AccountId>>
Queries the account id that owns the namespace
Sourcepub fn query_namespaces(
&self,
accounts: Vec<AccountId>,
querier: &QuerierWrapper<'_>,
) -> RegistryResult<NamespacesResponse>
pub fn query_namespaces( &self, accounts: Vec<AccountId>, querier: &QuerierWrapper<'_>, ) -> RegistryResult<NamespacesResponse>
Queries the namespaces owned by accounts
Sourcepub fn query_standalone_info_raw(
&self,
code_id: u64,
querier: &QuerierWrapper<'_>,
) -> RegistryResult<ModuleInfo>
pub fn query_standalone_info_raw( &self, code_id: u64, querier: &QuerierWrapper<'_>, ) -> RegistryResult<ModuleInfo>
Queries the module info of the standalone code id
Sourcepub fn query_service_info_raw(
&self,
service_addr: &Addr,
querier: &QuerierWrapper<'_>,
) -> RegistryResult<ModuleInfo>
pub fn query_service_info_raw( &self, service_addr: &Addr, querier: &QuerierWrapper<'_>, ) -> RegistryResult<ModuleInfo>
Queries the module info of the standalone code id
Sourcepub fn unchecked_account_id(
&self,
maybe_core_contract_addr: &Addr,
querier: &QuerierWrapper<'_>,
) -> RegistryResult<AccountId>
pub fn unchecked_account_id( &self, maybe_core_contract_addr: &Addr, querier: &QuerierWrapper<'_>, ) -> RegistryResult<AccountId>
Get self reported Account id, for checked use
RegistryContract::account_id
Sourcepub fn account_id(
&self,
maybe_account_addr: &Addr,
querier: &QuerierWrapper<'_>,
) -> RegistryResult<AccountId>
pub fn account_id( &self, maybe_account_addr: &Addr, querier: &QuerierWrapper<'_>, ) -> RegistryResult<AccountId>
Get AccountId for given account address. Also verifies that that address is indeed an account.
Sourcepub fn account(
&self,
account_id: &AccountId,
querier: &QuerierWrapper<'_>,
) -> RegistryResult<Account>
pub fn account( &self, account_id: &AccountId, querier: &QuerierWrapper<'_>, ) -> RegistryResult<Account>
Get the account for a given account id.
Sourcepub fn namespace_registration_fee(
&self,
querier: &QuerierWrapper<'_>,
) -> RegistryResult<Option<Coin>>
pub fn namespace_registration_fee( &self, querier: &QuerierWrapper<'_>, ) -> RegistryResult<Option<Coin>>
Get namespace registration fee
Sourcepub fn assert_account(
&self,
maybe_account: &Addr,
querier: &QuerierWrapper<'_>,
) -> RegistryResult<Account>
pub fn assert_account( &self, maybe_account: &Addr, querier: &QuerierWrapper<'_>, ) -> RegistryResult<Account>
Verify if the provided account address is indeed a user.
Trait Implementations§
Source§impl Clone for RegistryContract
impl Clone for RegistryContract
Source§fn clone(&self) -> RegistryContract
fn clone(&self) -> RegistryContract
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moreSource§impl Debug for RegistryContract
impl Debug for RegistryContract
Source§impl<'de> Deserialize<'de> for RegistryContract
impl<'de> Deserialize<'de> for RegistryContract
Source§fn 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>,
Source§impl JsonSchema for RegistryContract
impl JsonSchema for RegistryContract
Source§fn schema_name() -> String
fn schema_name() -> String
Source§fn schema_id() -> Cow<'static, str>
fn schema_id() -> Cow<'static, str>
Source§fn json_schema(gen: &mut SchemaGenerator) -> Schema
fn json_schema(gen: &mut SchemaGenerator) -> Schema
Source§fn is_referenceable() -> bool
fn is_referenceable() -> bool
$ref
keyword. Read moreSource§impl PartialEq for RegistryContract
impl PartialEq for RegistryContract
Source§impl Serialize for RegistryContract
impl Serialize for RegistryContract
impl StructuralPartialEq for RegistryContract
Auto Trait Implementations§
impl Freeze for RegistryContract
impl RefUnwindSafe for RegistryContract
impl Send for RegistryContract
impl Sync for RegistryContract
impl Unpin for RegistryContract
impl UnwindSafe for RegistryContract
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
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>
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>
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