pub struct WorkflowRuntime { /* private fields */ }Expand description
Non-clone scheduler and display owner for one declared workflow plan.
Implementations§
Source§impl WorkflowRuntime
impl WorkflowRuntime
Sourcepub fn builder() -> WorkflowRuntimeBuilder
pub fn builder() -> WorkflowRuntimeBuilder
Starts an empty builder. At least one phase is mandatory.
Sourcepub fn phases(&self) -> &[Phase]
pub fn phases(&self) -> &[Phase]
Borrows all registered phases in deterministic declaration order.
Sourcepub fn phase(&self, id: impl Into<PhaseId>) -> Option<&Phase>
pub fn phase(&self, id: impl Into<PhaseId>) -> Option<&Phase>
Borrows one registered phase by stable ID.
Sourcepub fn cancellation_token(&self) -> CancellationToken
pub fn cancellation_token(&self) -> CancellationToken
Returns a cheap token that can request or observe runtime cancellation.
Sourcepub fn unique_task_matching(
&self,
selector: &TaskSelector,
) -> Result<&Task, RuntimeError>
pub fn unique_task_matching( &self, selector: &TaskSelector, ) -> Result<&Task, RuntimeError>
Returns the unique task matching an exact partial selector.
Sourcepub fn run_phases<I, P>(self, phases: I) -> Result<RuntimeSummary, RuntimeError>
pub fn run_phases<I, P>(self, phases: I) -> Result<RuntimeSummary, RuntimeError>
Runs exactly the selected phases; omitted unsatisfied dependencies fail.
Sourcepub fn run_phases_exact<I, P>(
self,
phases: I,
) -> Result<RuntimeSummary, RuntimeError>
pub fn run_phases_exact<I, P>( self, phases: I, ) -> Result<RuntimeSummary, RuntimeError>
Runs exactly the selected phases; omitted unsatisfied dependencies fail.
Sourcepub fn run_phases_with_dependencies<I, P>(
self,
phases: I,
) -> Result<RuntimeSummary, RuntimeError>
pub fn run_phases_with_dependencies<I, P>( self, phases: I, ) -> Result<RuntimeSummary, RuntimeError>
Adds unsatisfied dependencies and runs the deterministic closure.
Trait Implementations§
Auto Trait Implementations§
impl !RefUnwindSafe for WorkflowRuntime
impl !Sync for WorkflowRuntime
impl !UnwindSafe for WorkflowRuntime
impl Freeze for WorkflowRuntime
impl Send for WorkflowRuntime
impl Unpin for WorkflowRuntime
impl UnsafeUnpin for WorkflowRuntime
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