pub struct Control { /* private fields */ }Expand description
The control half of a running build: cancel + await the outcome.
Implementations§
Source§impl Control
impl Control
Sourcepub fn cancel_token(&self) -> CancellationToken
pub fn cancel_token(&self) -> CancellationToken
A clone of the cancellation token (hand to a Ctrl-C handler).
Sourcepub async fn wait(self) -> Result<BuildOutcome>
pub async fn wait(self) -> Result<BuildOutcome>
Await the terminal outcome.
§Errors
Returns BackendError::Other if the spawned task panicked, or any
BackendError the backend task itself returned.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Control
impl RefUnwindSafe for Control
impl Send for Control
impl Sync for Control
impl Unpin for Control
impl UnsafeUnpin for Control
impl UnwindSafe for Control
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