#[repr(C)]pub struct WSClient<'a, T: Clone> { /* private fields */ }
Implementations§
Source§impl<'a, T> WSClient<'a, T>where
T: Clone,
impl<'a, T> WSClient<'a, T>where
T: Clone,
pub fn new() -> Self
pub fn init( &mut self, host: &'a str, port: u16, path: &'a str, config: Option<Config<'a, T>>, )
pub fn protocol(&self) -> Option<&str>
pub fn set_message_size(&mut self, size: u64)
pub fn set_timeout(&mut self, timeout: Duration)
pub fn send(&mut self, payload: &str)
pub fn event_loop(&mut self) -> WebSocketResult<()>
Trait Implementations§
impl<'a, T> Send for WSClient<'a, T>where
T: Clone,
Auto Trait Implementations§
impl<'a, T> Freeze for WSClient<'a, T>where
T: Freeze,
impl<'a, T> !RefUnwindSafe for WSClient<'a, T>
impl<'a, T> !Sync for WSClient<'a, T>
impl<'a, T> Unpin for WSClient<'a, T>where
T: Unpin,
impl<'a, T> !UnwindSafe for WSClient<'a, T>
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