Enum tk_http::websocket::Packet
[−]
[src]
pub enum Packet { Ping(Vec<u8>), Pong(Vec<u8>), Text(String), Binary(Vec<u8>), Close(u16, String), }
A websocket packet
Note: unlike Frame
this has data allocated on the heap so has static
lifetime
Variants
Ping(Vec<u8>)
Ping packet (with data)
Pong(Vec<u8>)
Pong packet (with data)
Text(String)
Text (utf-8) messsage
Binary(Vec<u8>)
Binary message
Close(u16, String)
Close message
Trait Implementations
impl Debug for Packet
[src]
fn fmt(&self, __arg_0: &mut Formatter) -> Result
[src]
Formats the value using the given formatter. Read more
impl Clone for Packet
[src]
fn clone(&self) -> Packet
[src]
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
Performs copy-assignment from source
. Read more