pub struct PluginRegistry { /* private fields */ }Expand description
Plugin registry for managing loaded plugins
Implementations§
Source§impl PluginRegistry
impl PluginRegistry
Sourcepub fn add_plugin(&mut self, plugin: PluginInstance) -> LoaderResult<()>
pub fn add_plugin(&mut self, plugin: PluginInstance) -> LoaderResult<()>
Add a plugin to the registry
Sourcepub fn remove_plugin(
&mut self,
plugin_id: &PluginId,
) -> LoaderResult<PluginInstance>
pub fn remove_plugin( &mut self, plugin_id: &PluginId, ) -> LoaderResult<PluginInstance>
Remove a plugin from the registry
Sourcepub fn get_plugin(&self, plugin_id: &PluginId) -> Option<&PluginInstance>
pub fn get_plugin(&self, plugin_id: &PluginId) -> Option<&PluginInstance>
Get a plugin by ID
Sourcepub fn get_plugin_mut(
&mut self,
plugin_id: &PluginId,
) -> Option<&mut PluginInstance>
pub fn get_plugin_mut( &mut self, plugin_id: &PluginId, ) -> Option<&mut PluginInstance>
Get a mutable reference to a plugin
Sourcepub fn has_plugin(&self, plugin_id: &PluginId) -> bool
pub fn has_plugin(&self, plugin_id: &PluginId) -> bool
Check if a plugin is registered
Sourcepub fn list_plugins(&self) -> Vec<PluginId>
pub fn list_plugins(&self) -> Vec<PluginId>
List all registered plugins
Sourcepub fn get_plugin_health(
&self,
plugin_id: &PluginId,
) -> LoaderResult<PluginHealth>
pub fn get_plugin_health( &self, plugin_id: &PluginId, ) -> LoaderResult<PluginHealth>
Get plugin health status
Sourcepub fn get_stats(&self) -> &RegistryStats
pub fn get_stats(&self) -> &RegistryStats
Get registry statistics
Sourcepub fn is_version_compatible(
&self,
requirement: &str,
version: &PluginVersion,
) -> bool
pub fn is_version_compatible( &self, requirement: &str, version: &PluginVersion, ) -> bool
Check if a version requirement is compatible with a plugin version
Sourcepub fn find_plugins_by_capability(
&self,
capability: &str,
) -> Vec<&PluginInstance>
pub fn find_plugins_by_capability( &self, capability: &str, ) -> Vec<&PluginInstance>
Find plugins by capability
Sourcepub fn get_plugins_in_dependency_order(&self) -> Vec<&PluginInstance>
pub fn get_plugins_in_dependency_order(&self) -> Vec<&PluginInstance>
Get plugins in dependency order
Sourcepub fn get_dependency_graph(&self) -> HashMap<PluginId, Vec<PluginId>>
pub fn get_dependency_graph(&self) -> HashMap<PluginId, Vec<PluginId>>
Get plugin dependency graph
Sourcepub fn get_initialization_order(&self) -> LoaderResult<Vec<PluginId>>
pub fn get_initialization_order(&self) -> LoaderResult<Vec<PluginId>>
Perform topological sort for plugin initialization
Sourcepub fn health_status(&self) -> RegistryHealth
pub fn health_status(&self) -> RegistryHealth
Get registry health status
Trait Implementations§
Source§impl Default for PluginRegistry
impl Default for PluginRegistry
impl Send for PluginRegistry
impl Sync for PluginRegistry
Auto Trait Implementations§
impl Freeze for PluginRegistry
impl RefUnwindSafe for PluginRegistry
impl Unpin for PluginRegistry
impl UnwindSafe for PluginRegistry
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> GetSetFdFlags for T
impl<T> GetSetFdFlags for T
Source§fn get_fd_flags(&self) -> Result<FdFlags, Error>where
T: AsFilelike,
fn get_fd_flags(&self) -> Result<FdFlags, Error>where
T: AsFilelike,
Query the “status” flags for the
self file descriptor.Source§fn new_set_fd_flags(&self, fd_flags: FdFlags) -> Result<SetFdFlags<T>, Error>where
T: AsFilelike,
fn new_set_fd_flags(&self, fd_flags: FdFlags) -> Result<SetFdFlags<T>, Error>where
T: AsFilelike,
Source§fn set_fd_flags(&mut self, set_fd_flags: SetFdFlags<T>) -> Result<(), Error>where
T: AsFilelike,
fn set_fd_flags(&mut self, set_fd_flags: SetFdFlags<T>) -> Result<(), Error>where
T: AsFilelike,
Set the “status” flags for the
self file descriptor. Read moreSource§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 more