pub struct Dispatcher<T: Send + 'static> { /* private fields */ }
Implementations§
Source§impl<T: Clone + Send + 'static> Dispatcher<T>
impl<T: Clone + Send + 'static> Dispatcher<T>
pub fn new() -> Self
pub fn new_bounded(limit: usize) -> Self
pub async fn cleanup(&self)
pub async fn dispatch(&self, event: T)
pub async fn dispatch_wait(&self, event: T)
pub async fn subscriber_count(&self) -> usize
pub async fn subscribe(&self) -> Subscriber<T>
Trait Implementations§
Auto Trait Implementations§
impl<T> Freeze for Dispatcher<T>
impl<T> !RefUnwindSafe for Dispatcher<T>
impl<T> Send for Dispatcher<T>
impl<T> Sync for Dispatcher<T>
impl<T> Unpin for Dispatcher<T>
impl<T> !UnwindSafe for Dispatcher<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