#[repr(u16)]pub enum CloseCode {
Normal = 1_000,
Away = 1_001,
Protocol = 1_002,
Unsupported = 1_003,
Invalid = 1_007,
Policy = 1_008,
Size = 1_009,
Extension = 1_010,
Error = 1_011,
Tls = 1_015,
Other(u16),
}Expand description
WebSocket close code
Variants§
Normal = 1_000
Normal closure
Away = 1_001
Endpoint going away
Protocol = 1_002
Protocol error
Unsupported = 1_003
Unsupported data
Invalid = 1_007
Invalid frame payload data
Policy = 1_008
Policy violation
Size = 1_009
Message too big
Extension = 1_010
Extension negotiation failure
Error = 1_011
Unexpected condition
Tls = 1_015
TLS handshake failure
Other(u16)
Other code
Trait Implementations§
impl Copy for CloseCode
impl Eq for CloseCode
impl StructuralPartialEq for CloseCode
Auto Trait Implementations§
impl Freeze for CloseCode
impl RefUnwindSafe for CloseCode
impl Send for CloseCode
impl Sync for CloseCode
impl Unpin for CloseCode
impl UnwindSafe for CloseCode
Blanket Implementations§
§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§unsafe fn clone_to_uninit(&self, dest: *mut u8)
unsafe fn clone_to_uninit(&self, dest: *mut u8)
🔬This is a nightly-only experimental API. (
clone_to_uninit)Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.