pub struct PluginRegistry { /* private fields */ }Implementations§
Source§impl PluginRegistry
impl PluginRegistry
pub fn new() -> Self
pub fn register( &mut self, create: fn() -> Box<dyn Plugin>, manifest: PluginManifest, )
pub fn get(&self, provider_type: &str) -> Option<&dyn Plugin>
pub fn create(&self, provider_type: &str) -> Option<Box<dyn Plugin>>
pub fn metadata(&self) -> impl Iterator<Item = &PluginMetadata>
pub fn metadata_of(&self, provider_type: &str) -> Option<&PluginMetadata>
pub fn is_registered(&self, provider_type: &str) -> bool
pub fn provider_types(&self) -> Vec<String>
pub fn count(&self) -> usize
Trait Implementations§
Auto Trait Implementations§
impl !RefUnwindSafe for PluginRegistry
impl !UnwindSafe for PluginRegistry
impl Forget for PluginRegistry
impl Freeze for PluginRegistry
impl Send for PluginRegistry
impl Sync for PluginRegistry
impl Unpin for PluginRegistry
impl UnsafeUnpin 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