pub struct WebsocketService { /* private fields */ }Expand description
A service which clients & servers use to drive the websocket connection. Handles connection status & close frames, as well as logging & protocol errors.
Trait Implementations§
Source§impl Debug for WebsocketService
impl Debug for WebsocketService
Source§impl Service for WebsocketService
impl Service for WebsocketService
Source§type Bus = WebsocketConnectionBus
type Bus = WebsocketConnectionBus
The bus, which must be provided to spawn the task
Source§type Lifeline = Result<WebsocketService, WebsocketSpawnError>
type Lifeline = Result<WebsocketService, WebsocketSpawnError>
The service lifeline. When dropped, all spawned tasks are immediately cancelled.
Source§fn spawn(bus: &WebsocketConnectionBus) -> Result<Self, WebsocketSpawnError>
fn spawn(bus: &WebsocketConnectionBus) -> Result<Self, WebsocketSpawnError>
Spawns the service with all sub-tasks, and returns a lifeline value. When the lifeline is dropped, all spawned tasks are immediately cancelled. Read more
Auto Trait Implementations§
impl Freeze for WebsocketService
impl !RefUnwindSafe for WebsocketService
impl Send for WebsocketService
impl Sync for WebsocketService
impl Unpin for WebsocketService
impl !UnwindSafe for WebsocketService
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