pub struct WsShutdown { /* private fields */ }Expand description
A cheap, cloneable, Send handle that force-closes a WebSocket’s socket
from any thread — unblocking a WsReader parked in recv
even if the peer has gone silent. Unlike WsWriter::close (a graceful
close frame), this shuts the underlying connection so the blocking read
returns at once; use it on shutdown so a reader can run with no read timeout.
Implementations§
Trait Implementations§
Source§impl Clone for WsShutdown
impl Clone for WsShutdown
Source§fn clone(&self) -> WsShutdown
fn clone(&self) -> WsShutdown
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for WsShutdown
impl RefUnwindSafe for WsShutdown
impl Send for WsShutdown
impl Sync for WsShutdown
impl Unpin for WsShutdown
impl UnsafeUnpin for WsShutdown
impl UnwindSafe for WsShutdown
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