Skip to main content

Gate

Trait Gate 

Source
pub trait Gate {
    // Required methods
    fn name(&self) -> &str;
    fn kind(&self) -> GateKind;
    fn evaluate(&self) -> GateOutcome;
}
Expand description

A gate: an ordered, typed, independently registrable check.

Gates capture everything they need at construction (paths, suites, executors, sessions) so registration is uniform; evaluate takes no shared context because a shell-command gate and a scrutiny gate share no honest input type.

Required Methods§

Source

fn name(&self) -> &str

Stable identity for reports and (later) persisted events.

Source

fn kind(&self) -> GateKind

Selects the pipeline section; deterministic gates evaluate first.

Source

fn evaluate(&self) -> GateOutcome

Run the check and return its outcome.

Dyn Compatibility§

This trait is dyn compatible.

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

Implementors§

Source§

impl Gate for PackGate

Source§

impl Gate for PreparedGate

Source§

impl<F> Gate for MergeSuiteGate<F>
where F: Fn(&str, &Path) -> (bool, String),