[][src]Struct ommui_broadcast::Broadcaster

pub struct Broadcaster<T: Clone> { /* fields omitted */ }

A broadcaster which sends out broadcasts to all of it's subscribers.

Methods

impl<T: Clone> Broadcaster<T>[src]

pub fn process_pending_subscriptions(&mut self)[src]

Process all pending subscriptions.

pub fn process_pending_subscriptions_with<F: FnMut(&mut Sender<T>)>(
    &mut self,
    f: &mut F
)
[src]

Process all pending subscriptions. This method calls a function on each sender before adding it.

pub fn broadcast(&mut self, item: T)[src]

Broadcast a message to all subscribers.

pub fn subscription_manager(&self) -> SubscriptionManager<T>[src]

Get a subscription manager which can be cloned or sent.

Trait Implementations

impl<T: Clone> SubscriptionRegistration<T> for Broadcaster<T>[src]

impl<T: Clone> Default for Broadcaster<T>[src]

impl<T: Clone> Clone for Broadcaster<T>[src]

Auto Trait Implementations

impl<T> Send for Broadcaster<T> where
    T: Send

impl<T> Unpin for Broadcaster<T>

impl<T> Sync for Broadcaster<T> where
    T: Send

impl<T> UnwindSafe for Broadcaster<T>

impl<T> RefUnwindSafe for Broadcaster<T>

Blanket Implementations

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> From<T> for T[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> Any for T where
    T: 'static + ?Sized
[src]