pub trait TraitPlugin: Send + Sync {
// Required methods
fn id(&self) -> &str;
fn name(&self) -> &str;
fn meta(&self) -> &PluginMeta;
fn value_types(&self) -> &[String];
fn check(&self, value: &CoreValue) -> Option<String>;
}Expand description
Trait for trait plugins that observe properties of values.
Required Methods§
Sourcefn meta(&self) -> &PluginMeta
fn meta(&self) -> &PluginMeta
Plugin metadata.
Sourcefn value_types(&self) -> &[String]
fn value_types(&self) -> &[String]
Value types this trait checks (e.g., [“int”]). Empty means it checks all types.