pub struct WorkRun { /* private fields */ }Expand description
Live process-owned handle returned immediately from submission.
Implementations§
Source§impl WorkRun
impl WorkRun
pub fn work_id(&self) -> WorkId
pub fn work_status(&self) -> WorkRunStatus
pub fn deadline(&self) -> Option<Instant>
pub fn cancellation_token(&self) -> WorkCancellationToken
Sourcepub fn work_result(&self) -> Promise
pub fn work_result(&self) -> Promise
Return the same native result Promise on every call.
pub fn work_cancel(&self, reason: Value) -> Promise
pub fn work_events(&self, after: usize) -> Value
Sourcepub fn emit(&self, kind: Value, data: Value) -> bool
pub fn emit(&self, kind: Value, data: Value) -> bool
Append one ordered domain event to this live run.
pub fn cancel(&self, reason: Value) -> bool
pub fn closed(&self) -> bool
pub fn same_identity(&self, other: &Self) -> bool
Trait Implementations§
Auto Trait Implementations§
impl !RefUnwindSafe for WorkRun
impl !Send for WorkRun
impl !Sync for WorkRun
impl !UnwindSafe for WorkRun
impl Freeze for WorkRun
impl Unpin for WorkRun
impl UnsafeUnpin for WorkRun
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more