pub struct WsIoEventRegistry<C: Send + Sync + 'static, S: TaskSpawner> { /* private fields */ }Implementations§
Source§impl<C: Send + Sync + 'static, S: TaskSpawner> WsIoEventRegistry<C, S>
impl<C: Send + Sync + 'static, S: TaskSpawner> WsIoEventRegistry<C, S>
pub fn new() -> Self
pub fn dispatch_event_packet( &self, ctx: Arc<C>, event: &str, packet_codec: &WsIoPacketCodec, packet_data: Option<Vec<u8>>, task_spawner: &Arc<S>, )
pub fn off(&self, event: &str)
pub fn off_by_handler_id(&self, event: &str, handler_id: u32)
pub fn on<H, Fut, D>(&self, event: &str, handler: H) -> u32
Trait Implementations§
Auto Trait Implementations§
impl<C, S> !Freeze for WsIoEventRegistry<C, S>
impl<C, S> !RefUnwindSafe for WsIoEventRegistry<C, S>
impl<C, S> Send for WsIoEventRegistry<C, S>
impl<C, S> Sync for WsIoEventRegistry<C, S>
impl<C, S> Unpin for WsIoEventRegistry<C, S>where
S: Unpin,
impl<C, S> !UnwindSafe for WsIoEventRegistry<C, S>
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