Struct abstract_sdk::ModuleRegistry
source · pub struct ModuleRegistry<'a, T: ModuleRegistryInterface> { /* private fields */ }
Expand description
API for querying module information from the Abstract version control contract.
§Example
use abstract_sdk::prelude::*;
let mod_registry: ModuleRegistry<MockModule> = module.module_registry(deps.as_ref()).unwrap();
Implementations§
source§impl<'a, T: ModuleRegistryInterface> ModuleRegistry<'a, T>
impl<'a, T: ModuleRegistryInterface> ModuleRegistry<'a, T>
sourcepub fn query_module_reference_raw(
&self,
module_info: &ModuleInfo,
) -> AbstractSdkResult<ModuleReference>
pub fn query_module_reference_raw( &self, module_info: &ModuleInfo, ) -> AbstractSdkResult<ModuleReference>
Raw query for a module reference
sourcepub fn query_module(&self, module_info: ModuleInfo) -> AbstractSdkResult<Module>
pub fn query_module(&self, module_info: ModuleInfo) -> AbstractSdkResult<Module>
Smart query for a module
sourcepub fn query_config(
&self,
module_info: ModuleInfo,
) -> AbstractSdkResult<ModuleConfiguration>
pub fn query_config( &self, module_info: ModuleInfo, ) -> AbstractSdkResult<ModuleConfiguration>
Smart query for a module config
sourcepub fn query_modules_configs(
&self,
infos: Vec<ModuleInfo>,
) -> AbstractSdkResult<Vec<ModuleResponse>>
pub fn query_modules_configs( &self, infos: Vec<ModuleInfo>, ) -> AbstractSdkResult<Vec<ModuleResponse>>
Smart query for a modules and its configurations
sourcepub fn query_namespace(
&self,
namespace: Namespace,
) -> AbstractSdkResult<NamespaceResponse>
pub fn query_namespace( &self, namespace: Namespace, ) -> AbstractSdkResult<NamespaceResponse>
Queries the account that owns the namespace Is also returns the base modules of that account (AccountBase)
sourcepub fn query_namespaces(
&self,
accounts: Vec<AccountId>,
) -> AbstractSdkResult<NamespacesResponse>
pub fn query_namespaces( &self, accounts: Vec<AccountId>, ) -> AbstractSdkResult<NamespacesResponse>
Queries the namespaces owned by accounts
sourcepub fn query_standalone_info_raw(
&self,
code_id: u64,
) -> AbstractSdkResult<ModuleInfo>
pub fn query_standalone_info_raw( &self, code_id: u64, ) -> AbstractSdkResult<ModuleInfo>
Queries the module info of the standalone code id
sourcepub fn module_info(&self, address: Addr) -> AbstractSdkResult<Module>
pub fn module_info(&self, address: Addr) -> AbstractSdkResult<Module>
Queries the Module information for an address. This will error if the Address is not an Abstract Module (Native, Account, App, Adapter or Standalone)
Trait Implementations§
source§impl<'a, T: Clone + ModuleRegistryInterface> Clone for ModuleRegistry<'a, T>
impl<'a, T: Clone + ModuleRegistryInterface> Clone for ModuleRegistry<'a, T>
source§fn clone(&self) -> ModuleRegistry<'a, T>
fn clone(&self) -> ModuleRegistry<'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 ModuleRegistry<'a, T>
impl<'a, T> !RefUnwindSafe for ModuleRegistry<'a, T>
impl<'a, T> !Send for ModuleRegistry<'a, T>
impl<'a, T> !Sync for ModuleRegistry<'a, T>
impl<'a, T> Unpin for ModuleRegistry<'a, T>
impl<'a, T> !UnwindSafe for ModuleRegistry<'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> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§default unsafe fn clone_to_uninit(&self, dst: *mut T)
default unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)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