Struct rust_xfinal::Websocket
source · pub struct Websocket { /* private fields */ }Implementations§
source§impl Websocket
impl Websocket
sourcepub fn write(&self, data: Vec<u8>, opcode: u8)
pub fn write(&self, data: Vec<u8>, opcode: u8)
Write the data whose type is specified by the sceond parameter to peer
The method is thread safety
sourcepub fn write_string(&self, s: &str)
pub fn write_string(&self, s: &str)
Conveniently to write string data to peer
The method is thread safety
sourcepub fn write_binary(&self, data: Vec<u8>)
pub fn write_binary(&self, data: Vec<u8>)
Conveniently to write binary data to peer
The method is thread safety