Skip to main content

Node

Trait Node 

Source
pub trait Node: Send + Sync {
    // Required methods
    fn name(&self) -> &str;
    fn execute<'life0, 'async_trait>(
        &'life0 self,
        state: NodeState,
    ) -> Pin<Box<dyn Future<Output = Result<NodeState>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
}
Expand description

Node trait - a single step in a graph

Required Methods§

Source

fn name(&self) -> &str

Node name (unique within graph)

Source

fn execute<'life0, 'async_trait>( &'life0 self, state: NodeState, ) -> Pin<Box<dyn Future<Output = Result<NodeState>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Execute the node

Implementors§