GenericNotify

Struct GenericNotify 

Source
pub(crate) struct GenericNotify<F> {
    count: usize,
    additional: bool,
    tags: F,
}
Expand description

A generic notification.

Fields§

§count: usize

Number of listeners to notify.

§additional: bool

Whether this notification is additional.

§tags: F

Generate tags.

Implementations§

Source§

impl<T, F: TagProducer<Tag = T>> GenericNotify<F>

Source

pub(crate) fn new(count: usize, additional: bool, tags: F) -> Self

Trait Implementations§

Source§

impl<F: Debug> Debug for GenericNotify<F>

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more

Auto Trait Implementations§

§

impl<F> Freeze for GenericNotify<F>
where F: Freeze,

§

impl<F> RefUnwindSafe for GenericNotify<F>
where F: RefUnwindSafe,

§

impl<F> Send for GenericNotify<F>
where F: Send,

§

impl<F> Sync for GenericNotify<F>
where F: Sync,

§

impl<F> Unpin for GenericNotify<F>
where F: Unpin,

§

impl<F> UnwindSafe for GenericNotify<F>
where F: UnwindSafe,

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<N> IntoNotification for N
where N: Notification,

Source§

type Tag = <N as NotificationPrivate>::Tag

The tag data associated with a notification. Read more
Source§

type Notify = N

The notification type. Read more
Source§

fn into_notification(self) -> <N as IntoNotification>::Notify

Convert this value into a notification. Read more
Source§

fn additional(self) -> Additional<Self::Notify>
where Self: Sized,

Convert this value into an additional notification. Read more
Source§

fn relaxed(self) -> Relaxed<Self::Notify>
where Self: Sized,

Don’t emit a fence for this notification. Read more
Source§

fn tag<T: Clone>(self, tag: T) -> Tag<Self::Notify, T>
where Self: Sized + IntoNotification<Tag = ()>,

Use a tag with this notification. Read more
Source§

fn tag_with<T, F>(self, tag: F) -> TagWith<Self::Notify, F>
where Self: Sized + IntoNotification<Tag = ()>, F: FnMut() -> T,

Use a function to generate a tag with this notification. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

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

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<N> Notification for N
where N: NotificationPrivate + ?Sized,