pub struct PluginRouter { /* private fields */ }Expand description
Dispatches plugin load requests to the wasm, CLAP, or LV2 loader.
Implementations§
Source§impl PluginRouter
impl PluginRouter
Sourcepub fn new(limits: WasmResourceLimits) -> Self
pub fn new(limits: WasmResourceLimits) -> Self
Builds a router with default wasm loading and no native provider overrides.
Sourcepub fn builder(limits: WasmResourceLimits) -> PluginRouterBuilder
pub fn builder(limits: WasmResourceLimits) -> PluginRouterBuilder
Starts configuring a plugin router.
Sourcepub fn load(&self, path: &Path, caps: &CapabilitySet) -> Result<RoutedPlugin>
pub fn load(&self, path: &Path, caps: &CapabilitySet) -> Result<RoutedPlugin>
Loads a plugin by inspecting path’s extension.
§Errors
Returns an eval error when the extension is unrecognised, when the selected feature is disabled, when no native provider is configured for a native route, or when the selected loader rejects the plugin.
Trait Implementations§
Source§impl Clone for PluginRouter
impl Clone for PluginRouter
Source§fn clone(&self) -> PluginRouter
fn clone(&self) -> PluginRouter
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · 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 Freeze for PluginRouter
impl RefUnwindSafe for PluginRouter
impl Send for PluginRouter
impl Sync for PluginRouter
impl Unpin for PluginRouter
impl UnsafeUnpin for PluginRouter
impl UnwindSafe for PluginRouter
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