Struct sn0int_std::websockets::WebSocket
source · pub struct WebSocket { /* private fields */ }
Implementations§
source§impl WebSocket
impl WebSocket
pub fn negotiate( stream: Stream, url: Url, headers: Option<&HashMap<String, String>> ) -> Result<WebSocket, Error>
pub fn connect<R: DnsResolver>( resolver: &R, url: Url, options: &WebSocketOptions ) -> Result<WebSocket, Error>
pub fn options(&self, options: &WebSocketOptions) -> Result<(), Error>
pub fn read_text(&mut self) -> Result<Option<String>, Error>
pub fn read_binary(&mut self) -> Result<Option<Vec<u8>>, Error>
pub fn write_text(&mut self, text: String) -> Result<(), Error>
pub fn write_binary(&mut self, binary: Vec<u8>) -> Result<(), Error>
Auto Trait Implementations§
impl !RefUnwindSafe for WebSocket
impl Send for WebSocket
impl Sync for WebSocket
impl Unpin for WebSocket
impl !UnwindSafe for WebSocket
Blanket Implementations§
§impl<'a, T> AsTaggedExplicit<'a> for Twhere
T: 'a,
impl<'a, T> AsTaggedExplicit<'a> for Twhere T: 'a,
§impl<'a, T> AsTaggedImplicit<'a> for Twhere
T: 'a,
impl<'a, T> AsTaggedImplicit<'a> for Twhere T: 'a,
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