pub trait NativePlugin: Send + Sync {
// Required methods
fn name(&self) -> &'static str;
fn description(&self) -> &'static str;
fn process(&self, input: PluginInput) -> PluginOutput;
}Expand description
Base capability for native plugins. Both SynthPlugin and
RegularPlugin extend this — every native plugin has these
three methods regardless of pass.
The bounds (Send + Sync) are the minimum to satisfy the
global singleton registry; the registry’s Box<dyn ...> storage
implicitly requires 'static, but the trait itself doesn’t add
that bound so external implementors can write borrowing impls
for non-registry use (testing helpers, ad-hoc adapters).
Required Methods§
Sourcefn name(&self) -> &'static str
fn name(&self) -> &'static str
Plugin name (short form — "implicit_prices", not the
fully-qualified module path).
Sourcefn description(&self) -> &'static str
fn description(&self) -> &'static str
Plugin description for --help and similar UI surfaces.
Sourcefn process(&self, input: PluginInput) -> PluginOutput
fn process(&self, input: PluginInput) -> PluginOutput
Process directives and return modified directives + errors.
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".