pub struct ShutdownHandle { /* private fields */ }Expand description
Cloneable, thread-safe handle that stops a MockServer (from a signal handler thread,
a stdin-close watcher, or a /shutdown route) and lets another thread wait for it.
Implementations§
Source§impl ShutdownHandle
impl ShutdownHandle
pub fn is_shutdown(&self) -> bool
Sourcepub fn wait(&self)
pub fn wait(&self)
Block until ShutdownHandle::shutdown is called (the main thread of a standalone mock).
Trait Implementations§
Auto Trait Implementations§
impl Freeze for ShutdownHandle
impl RefUnwindSafe for ShutdownHandle
impl Send for ShutdownHandle
impl Sync for ShutdownHandle
impl Unpin for ShutdownHandle
impl UnsafeUnpin for ShutdownHandle
impl UnwindSafe for ShutdownHandle
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