pub struct TerminateFlag(/* private fields */);Expand description
A Terminator that can be triggered from any thread, e.g. to stop a
long-running CaDiCal::solve after a timeout. Clones share the same flag.
Implementations§
Source§impl TerminateFlag
impl TerminateFlag
pub fn new() -> Self
Sourcepub fn terminate(&self)
pub fn terminate(&self)
Ask the solver to stop as soon as possible; solve then returns
Status::UNKNOWN unless it has already decided the formula.
pub fn is_terminated(&self) -> bool
Trait Implementations§
Source§impl Clone for TerminateFlag
impl Clone for TerminateFlag
Source§impl Debug for TerminateFlag
impl Debug for TerminateFlag
Source§impl Default for TerminateFlag
impl Default for TerminateFlag
Source§impl Terminator for TerminateFlag
impl Terminator for TerminateFlag
fn terminated(&mut self) -> bool
Auto Trait Implementations§
impl Freeze for TerminateFlag
impl RefUnwindSafe for TerminateFlag
impl Send for TerminateFlag
impl Sync for TerminateFlag
impl Unpin for TerminateFlag
impl UnsafeUnpin for TerminateFlag
impl UnwindSafe for TerminateFlag
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