Trait ToEvent

Source
pub trait ToEvent {
    type Props<'a>: Props
       where Self: 'a;

    // Required method
    fn to_event<'a>(&'a self) -> Event<'a, Self::Props<'a>>;
}
Expand description

Convert a value into an Event.

Required Associated Types§

Source

type Props<'a>: Props where Self: 'a

The kind of Props on the resulting value.

Required Methods§

Source

fn to_event<'a>(&'a self) -> Event<'a, Self::Props<'a>>

Perform the conversion.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementations on Foreign Types§

Source§

impl<'a, T: ToEvent + ?Sized> ToEvent for &'a T

Source§

type Props<'b> = <T as ToEvent>::Props<'b> where Self: 'b

Source§

fn to_event<'b>(&'b self) -> Event<'b, Self::Props<'b>>

Implementors§

Source§

impl<'a, P: Props> ToEvent for Event<'a, P>

Source§

type Props<'b> = &'b P where Self: 'b