Skip to main content

EventSource

Trait EventSource 

Source
pub trait EventSource {
    const SOURCE: Option<&'static str>;
}
Expand description

Provide an event source name for an event type

This is required to use that type as an event payload

Required Associated Constants§

Source

const SOURCE: Option<&'static str>

Source name

syscall for system call events, an arbitrary string (matching the one in the source plugin implementation) for custom plugin/async events

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementations on Foreign Types§

Source§

impl EventSource for &[u8]

Source§

const SOURCE: Option<&'static str> = None

Implementors§

Source§

impl<T> EventSource for JsonPayload<T>
where T: EventSource,

Source§

const SOURCE: Option<&'static str> = T::SOURCE