pub enum State {
Working,
Completed,
Paused,
Cancelled,
}
Expand description
Represents the state of a progress-tracked operation.
Variants§
Working
The operation is in progress.
Completed
The operation has been completed successfully.
Paused
The operation has been paused.
Cancelled
The operation has been cancelled.
Implementations§
Source§impl State
impl State
Sourcepub const fn is_cancelled(&self) -> bool
pub const fn is_cancelled(&self) -> bool
Returns true
if the state is Cancelled
.
Sourcepub const fn is_working(&self) -> bool
pub const fn is_working(&self) -> bool
Returns true
if the state is Working
.
Sourcepub const fn is_completed(&self) -> bool
pub const fn is_completed(&self) -> bool
Returns true
if the state is Completed
.
Trait Implementations§
Source§impl Ord for State
impl Ord for State
Source§impl PartialOrd for State
impl PartialOrd for State
impl Copy for State
impl Eq for State
impl StructuralPartialEq for State
Auto Trait Implementations§
impl Freeze for State
impl RefUnwindSafe for State
impl Send for State
impl Sync for State
impl Unpin for State
impl UnwindSafe for State
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