Skip to main content

PracticeRule

Trait PracticeRule 

Source
pub trait PracticeRule: Send + Sync {
    // Required methods
    fn id(&self) -> &PracticeRuleId;
    fn spec(&self) -> PracticeRuleSpec;
    fn evaluate(
        &self,
        plan: &SerialPlan,
        reading: SerialReading,
        waivers: &DeclaredWaivers,
    ) -> InvariantLedgerEntry<PracticeRuleId>;
}
Expand description

Open rule component used by one serial practice.

Required Methods§

Source

fn id(&self) -> &PracticeRuleId

Returns the stable rule identity.

Source

fn spec(&self) -> PracticeRuleSpec

Returns the inspectable rule specification.

Source

fn evaluate( &self, plan: &SerialPlan, reading: SerialReading, waivers: &DeclaredWaivers, ) -> InvariantLedgerEntry<PracticeRuleId>

Evaluates this rule over one named reading.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§