pub enum DisconnectReason {
Eof,
Silent(Duration),
Handshake(HandshakeError),
Protocol(String),
Closed,
}Expand description
Why a session closed.
Variants§
Eof
The other side closed the connection.
Silent(Duration)
Nothing arrived from the other side for this long.
Handshake(HandshakeError)
The handshake failed.
Protocol(String)
A message could not be decoded or was not expected.
Closed
This side closed the session.
Trait Implementations§
Source§impl Clone for DisconnectReason
impl Clone for DisconnectReason
Source§impl Debug for DisconnectReason
impl Debug for DisconnectReason
Source§impl Display for DisconnectReason
impl Display for DisconnectReason
impl Eq for DisconnectReason
Source§impl PartialEq for DisconnectReason
impl PartialEq for DisconnectReason
impl StructuralPartialEq for DisconnectReason
Auto Trait Implementations§
impl Freeze for DisconnectReason
impl RefUnwindSafe for DisconnectReason
impl Send for DisconnectReason
impl Sync for DisconnectReason
impl Unpin for DisconnectReason
impl UnsafeUnpin for DisconnectReason
impl UnwindSafe for DisconnectReason
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