pub struct Task {
pub id: u64,
pub action: String,
pub status: Status,
pub progress: Option<u16>,
pub message: String,
pub cancellable: bool,
pub result: Option<ActionResult>,
pub error: Option<ActionError>,
}Expand description
One task, isolated inside its app/connection owner.
Fields§
§id: u64Monotonically allocated identifier; never reused by a table.
action: StringSemantic action that created the task.
status: StatusCurrent lifecycle state.
progress: Option<u16>Progress in thousandths, when available.
message: StringShort host-provided progress description.
cancellable: boolWhether cancellation is supported at host interruption points.
result: Option<ActionResult>Completed result, available only in the Complete state.
error: Option<ActionError>Terminal failure or cancellation diagnosis.
Implementations§
Trait Implementations§
Auto Trait Implementations§
impl Forget for Task
impl Freeze for Task
impl RefUnwindSafe for Task
impl Send for Task
impl Sync for Task
impl Unpin for Task
impl UnsafeUnpin for Task
impl UnwindSafe for Task
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