pub struct ExtensionRegistry { /* private fields */ }Expand description
The statically compiled extensions available in one distribution.
Implementations§
Source§impl ExtensionRegistry
impl ExtensionRegistry
Sourcepub fn new(
extensions: impl IntoIterator<Item = Arc<dyn KnowledgeBaseExtension>>,
) -> Result<Self, FrameworkError>
pub fn new( extensions: impl IntoIterator<Item = Arc<dyn KnowledgeBaseExtension>>, ) -> Result<Self, FrameworkError>
Registers extensions after validating their metadata and declared dependencies.
Sourcepub fn resolve_active(
&self,
requested: impl IntoIterator<Item = ExtensionId>,
) -> Result<ActiveExtensions, FrameworkError>
pub fn resolve_active( &self, requested: impl IntoIterator<Item = ExtensionId>, ) -> Result<ActiveExtensions, FrameworkError>
Resolves an explicitly activated set into stable dependency-first order.
Sourcepub fn metadata(&self, id: &ExtensionId) -> Option<&ExtensionMetadata>
pub fn metadata(&self, id: &ExtensionId) -> Option<&ExtensionMetadata>
Returns compiled extension metadata by canonical identifier.
Sourcepub fn extensions(&self) -> impl Iterator<Item = &dyn KnowledgeBaseExtension>
pub fn extensions(&self) -> impl Iterator<Item = &dyn KnowledgeBaseExtension>
Returns every compiled extension in canonical identifier order.
Auto Trait Implementations§
impl !RefUnwindSafe for ExtensionRegistry
impl !UnwindSafe for ExtensionRegistry
impl Freeze for ExtensionRegistry
impl Send for ExtensionRegistry
impl Sync for ExtensionRegistry
impl Unpin for ExtensionRegistry
impl UnsafeUnpin for ExtensionRegistry
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