Struct stepflow::step::Step[][src]

pub struct Step {
    pub id: StepId,
    pub input_vars: Option<Vec<VarId, Global>>,
    pub output_vars: Vec<VarId, Global>,
    // some fields omitted
}

A single step in a flow

A step is defined by its the required inputs to enter the step and the outputs it must fulfill to exit the step. Substeps allow for grouping of steps and are executing in order by default.

Fields

id: StepIdinput_vars: Option<Vec<VarId, Global>>output_vars: Vec<VarId, Global>

Implementations

impl Step[src]

pub fn new(
    id: StepId,
    input_vars: Option<Vec<VarId, Global>>,
    output_vars: Vec<VarId, Global>
) -> Step
[src]

Create a new step.

If no inputs are required, pass in None for input_vars

pub fn get_input_vars(&self) -> &Option<Vec<VarId, Global>>[src]

pub fn get_output_vars(&self) -> &Vec<VarId, Global>[src]

pub fn push_substep(&mut self, substep_step_id: StepId)[src]

Push a substep to the end of the current sub-steps

pub fn next_substep(&self, prev_substep_id: &StepId) -> Option<&StepId>[src]

Get the sub-step that directly follows prev_substep_id

pub fn first_substep(&self) -> Option<&StepId>[src]

pub fn can_enter(&self, inputs: &StateData) -> Result<(), IdError<VarId>>[src]

Verifies that inputs fulfills the required inputs to enter the step

pub fn can_exit(&self, state_data: &StateData) -> Result<(), IdError<VarId>>[src]

Verifies that state_data fulfills the required outputs to exit the step

Trait Implementations

impl Debug for Step[src]

impl ObjectStoreContent for Step[src]

type IdType = StepId

Auto Trait Implementations

impl RefUnwindSafe for Step

impl Send for Step

impl Sync for Step

impl Unpin for Step

impl UnwindSafe for Step

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> AsAny for T where
    T: Any
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.