Struct workflow_core::abortable::Abortable
source · pub struct Abortable(_);Expand description
Abortable trigger wraps an Arc<AtomicBool>, which can be cloned
to signal task terminating using an atomic bool.
let abortable = Abortable::default();
let result = my_task(abortable).await?;
// ... elsewhere
abortable.abort();Implementations§
Trait Implementations§
Auto Trait Implementations§
impl RefUnwindSafe for Abortable
impl Send for Abortable
impl Sync for Abortable
impl Unpin for Abortable
impl UnwindSafe for Abortable
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