Skip to main content

Executor

Trait Executor 

Source
pub trait Executor: Send + Sync {
    // Required method
    fn execute_step<'a>(
        &'a mut self,
        step_description: &'a str,
        context: &'a str,
    ) -> Pin<Box<dyn Future<Output = Result<String, ReactError>> + Send + 'a>>;
}
Available on crate feature plan-execute only.
Expand description

Executor trait — executes a single step

  • step_description: Step description
  • context: Execution context (results from previous steps, etc.)

Required Methods§

Source

fn execute_step<'a>( &'a mut self, step_description: &'a str, context: &'a str, ) -> Pin<Box<dyn Future<Output = Result<String, ReactError>> + Send + 'a>>

Execute a single step

Dyn Compatibility§

This trait is dyn compatible.

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

Implementors§

Source§

impl Executor for ReflectiveExecutor

Available on crate feature self-reflection only.
Source§

impl Executor for ReactExecutor

Source§

impl Executor for SimpleExecutor