pub struct Catalog;Expand description
Provides deterministic access to statically registered providers and modules.
Implementations§
Source§impl Catalog
impl Catalog
Sourcepub fn providers() -> Vec<&'static ProviderDescriptor>
pub fn providers() -> Vec<&'static ProviderDescriptor>
Returns every registered provider in deterministic declaration order.
Sourcepub fn modules() -> Vec<&'static ModuleDescriptor>
pub fn modules() -> Vec<&'static ModuleDescriptor>
Returns every registered module in deterministic declaration order.
Sourcepub fn module_for<M: Module>() -> Result<&'static ModuleDescriptor>
pub fn module_for<M: Module>() -> Result<&'static ModuleDescriptor>
Selects the single static module descriptor registered for M.
Sourcepub fn provider_for<T>() -> Result<&'static ProviderDescriptor>
pub fn provider_for<T>() -> Result<&'static ProviderDescriptor>
Selects the single static provider registered for T.
Auto Trait Implementations§
impl Forget for Catalog
impl Freeze for Catalog
impl Move for Catalog
impl RefUnwindSafe for Catalog
impl Send for Catalog
impl Sync for Catalog
impl Unpin for Catalog
impl UnsafeUnpin for Catalog
impl UnwindSafe for Catalog
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