pub struct Runtime<'a> {
pub entity_id: String,
pub definition: &'a WorkflowDefinition,
pub instance: WorkflowState,
}Fields§
§entity_id: String§definition: &'a WorkflowDefinition§instance: WorkflowStateImplementations§
Source§impl<'a> Runtime<'a>
impl<'a> Runtime<'a>
pub fn new(definition: &'a WorkflowDefinition, entity_id: String) -> Self
pub fn with_state(self, state: State) -> Self
pub async fn replace(&self, state: State)
pub async fn complete(&self, task_id: i32) -> Result<(), String>
pub fn run<'life_self, 'async_recursion>(
&'life_self self,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_recursion>>where
'life_self: 'async_recursion,
pub async fn set_default_active_task(&self)
pub async fn simulate(&self)
pub async fn get_previous_user_task(&self, task_id: i32) -> Option<i32>
Auto Trait Implementations§
impl<'a> Freeze for Runtime<'a>
impl<'a> !RefUnwindSafe for Runtime<'a>
impl<'a> Send for Runtime<'a>
impl<'a> Sync for Runtime<'a>
impl<'a> Unpin for Runtime<'a>
impl<'a> !UnwindSafe for Runtime<'a>
Blanket Implementations§
Source§impl<T> ArchivePointee for T
impl<T> ArchivePointee for T
Source§type ArchivedMetadata = ()
type ArchivedMetadata = ()
The archived version of the pointer metadata for this type.
Source§fn pointer_metadata(
_: &<T as ArchivePointee>::ArchivedMetadata,
) -> <T as Pointee>::Metadata
fn pointer_metadata( _: &<T as ArchivePointee>::ArchivedMetadata, ) -> <T as Pointee>::Metadata
Converts some archived metadata to the pointer metadata for itself.
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
Source§impl<F, W, T, D> Deserialize<With<T, W>, D> for F
impl<F, W, T, D> Deserialize<With<T, W>, D> for F
Source§impl<T> LayoutRaw for T
impl<T> LayoutRaw for T
Source§fn layout_raw(_: <T as Pointee>::Metadata) -> Result<Layout, LayoutError>
fn layout_raw(_: <T as Pointee>::Metadata) -> Result<Layout, LayoutError>
Gets the layout of the type.