pub struct Subscriber<M>{ /* private fields */ }Expand description
A generic implementation of bus subscription using std::sync::mpsc
Trait Implementations§
Source§impl<M> Debug for Subscriber<M>
impl<M> Debug for Subscriber<M>
Source§impl<M> PartialEq for Subscriber<M>
impl<M> PartialEq for Subscriber<M>
Source§impl<M> Subscription for Subscriber<M>
impl<M> Subscription for Subscriber<M>
type Event = M
Source§fn subscribed_to(&self, message: &Self::Event) -> bool
fn subscribed_to(&self, message: &Self::Event) -> bool
Test whether this subscriiption is subscribed to a message
Source§fn discriminant_set(&self) -> &[<Self::Event as Message>::Discriminant]
fn discriminant_set(&self) -> &[<Self::Event as Message>::Discriminant]
Returns a slice of discriminants corresponding to messages this subsccription is subscribed to
Auto Trait Implementations§
impl<M> Freeze for Subscriber<M>
impl<M> RefUnwindSafe for Subscriber<M>
impl<M> Send for Subscriber<M>
impl<M> Sync for Subscriber<M>
impl<M> Unpin for Subscriber<M>
impl<M> UnwindSafe for Subscriber<M>
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