Struct reopen::Handle [−][src]
pub struct Handle(_);
Expand description
Implementations
Installs a signal handler to invoke the reopening when a certain signal comes.
Features
This is available only with the signals
feature enabled.
Notes
- Under the hood, this uses the
signal-hook
crate, so the same signal can be shared with other actions (to eg. also reload a configuration). - The same restrictions, errors and panics as in the case of
signal_hook::register
apply. - This installs a signal handler. Signal handlers are program-global entities, so you may be careful.
- If there are multiple handles for the same signal, they share their signal handler ‒ only the first one for each signal registers one.
- Upon signal registration, the original handler is stored and called in chain from our own signal handler.
- A single handle can be used for multiple signals.
- To unregister a handle from a signal handle, use the returned
SigId
and thesignal_hook::unregister
.
Trait Implementations
Auto Trait Implementations
impl RefUnwindSafe for Handle
impl UnwindSafe for Handle
Blanket Implementations
Mutably borrows from an owned value. Read more