Skip to main content

ActionCompute

Trait ActionCompute 

Source
pub trait ActionCompute: 'static {
    // Required method
    fn compute(&self, ctx: &ActionContext<'_>) -> Vec<Op>;
}
Expand description

User-written half of Action. The deterministic effect-list computation is the only domain logic the kernel runs.

Required Methods§

Source

fn compute(&self, ctx: &ActionContext<'_>) -> Vec<Op>

Translate this action into a list of Ops the kernel will then authorize, dispatch, and apply. Must be pure — A11 SOCIAL-CONTRACT until the subset-Rust checker promotes it to MACHINE-CHECKED.

Implementors§