pub trait Rule {
type Then: ThenAction;
// Required methods
fn id(&self) -> &str;
fn name(&self) -> &str;
fn enabled(&self) -> bool;
fn spec(&self) -> &RuleSpec<Self::Then>;
fn created_at(&self) -> i64;
fn last_run_at(&self) -> Option<i64>;
}Expand description
A stored rule, as the engine sees it.
Required Associated Types§
type Then: ThenAction
Required Methods§
fn id(&self) -> &str
fn name(&self) -> &str
fn enabled(&self) -> bool
fn spec(&self) -> &RuleSpec<Self::Then>
fn created_at(&self) -> i64
fn last_run_at(&self) -> Option<i64>
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".