pub struct PhaseGuard { /* private fields */ }Expand description
RAII guard for one occurrence of a named background phase. Increments the
phase’s count on creation (see register_active_phase); decrements on
Drop, so the count comes back down whether the guarded work returns
normally, panics, or is cancelled — the same rationale as
BackgroundTaskGuard above.
Trait Implementations§
Source§impl Drop for PhaseGuard
impl Drop for PhaseGuard
Auto Trait Implementations§
impl Freeze for PhaseGuard
impl RefUnwindSafe for PhaseGuard
impl Send for PhaseGuard
impl Sync for PhaseGuard
impl Unpin for PhaseGuard
impl UnsafeUnpin for PhaseGuard
impl UnwindSafe for PhaseGuard
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