pub struct ShutdownFlagGuard { /* private fields */ }Expand description
Guard that restores previous SIGINT/SIGTERM handlers and shutdown flag on drop.
§Fork Safety
The guard is owned by the process that created it. If the process forks, the child will also have a copy of the guard, but dropping it in the child will restore handlers in the child’s context only.
Trait Implementations§
Source§impl Drop for ShutdownFlagGuard
impl Drop for ShutdownFlagGuard
Auto Trait Implementations§
impl !Send for ShutdownFlagGuard
impl !Sync for ShutdownFlagGuard
impl Freeze for ShutdownFlagGuard
impl RefUnwindSafe for ShutdownFlagGuard
impl Unpin for ShutdownFlagGuard
impl UnsafeUnpin for ShutdownFlagGuard
impl UnwindSafe for ShutdownFlagGuard
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