pub enum OwnedMessage {
Text(String),
Binary(Vec<u8>),
Ping(Vec<u8>),
Pong(Vec<u8>),
Close(OwnedCloseFrame),
}Expand description
An owned WebSocket message, detached from reader buffers.
Variants§
Text(String)
UTF-8 text message.
Binary(Vec<u8>)
Binary message.
Ping(Vec<u8>)
Ping control frame.
Pong(Vec<u8>)
Pong control frame.
Close(OwnedCloseFrame)
Connection close.
Implementations§
Trait Implementations§
Source§impl Clone for OwnedMessage
impl Clone for OwnedMessage
Source§fn clone(&self) -> OwnedMessage
fn clone(&self) -> OwnedMessage
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 OwnedMessage
impl RefUnwindSafe for OwnedMessage
impl Send for OwnedMessage
impl Sync for OwnedMessage
impl Unpin for OwnedMessage
impl UnsafeUnpin for OwnedMessage
impl UnwindSafe for OwnedMessage
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