pub struct CompositionEngine { /* private fields */ }Expand description
Workflow composition algebra engine.
Implementations§
Source§impl CompositionEngine
impl CompositionEngine
pub fn new() -> Self
Sourcepub fn sequence(
&mut self,
name: &str,
workflow_ids: Vec<String>,
) -> WorkflowResult<String>
pub fn sequence( &mut self, name: &str, workflow_ids: Vec<String>, ) -> WorkflowResult<String>
Create a sequence composition: A → B → C.
Sourcepub fn parallel(
&mut self,
name: &str,
workflow_ids: Vec<String>,
) -> WorkflowResult<String>
pub fn parallel( &mut self, name: &str, workflow_ids: Vec<String>, ) -> WorkflowResult<String>
Create a parallel composition: A || B || C.
Sourcepub fn conditional(
&mut self,
name: &str,
predicate: &str,
if_true: &str,
if_false: &str,
) -> WorkflowResult<String>
pub fn conditional( &mut self, name: &str, predicate: &str, if_true: &str, if_false: &str, ) -> WorkflowResult<String>
Create a conditional composition: if pred then A else B.
Sourcepub fn add_bridge(
&mut self,
meta_id: &str,
from_workflow_id: &str,
from_output: &str,
to_workflow_id: &str,
to_input: &str,
transform: Option<String>,
) -> WorkflowResult<()>
pub fn add_bridge( &mut self, meta_id: &str, from_workflow_id: &str, from_output: &str, to_workflow_id: &str, to_input: &str, transform: Option<String>, ) -> WorkflowResult<()>
Add a data bridge between composed workflows.
Sourcepub fn validate(&self, meta_id: &str) -> WorkflowResult<Vec<String>>
pub fn validate(&self, meta_id: &str) -> WorkflowResult<Vec<String>>
Validate a composed meta-workflow.
Sourcepub fn get_meta(&self, meta_id: &str) -> WorkflowResult<&MetaWorkflow>
pub fn get_meta(&self, meta_id: &str) -> WorkflowResult<&MetaWorkflow>
Get a meta-workflow.
Sourcepub fn list_meta(&self) -> Vec<&MetaWorkflow>
pub fn list_meta(&self) -> Vec<&MetaWorkflow>
List all meta-workflows.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for CompositionEngine
impl RefUnwindSafe for CompositionEngine
impl Send for CompositionEngine
impl Sync for CompositionEngine
impl Unpin for CompositionEngine
impl UnsafeUnpin for CompositionEngine
impl UnwindSafe for CompositionEngine
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more