Trait ruma_events::Event
source · pub trait Eventwhere
Self: Debug + for<'a> Deserialize<'a> + Serialize,{
type Content: Debug + for<'a> Deserialize<'a> + Serialize;
fn content(&self) -> &Self::Content;
fn event_type(&self) -> &EventType;
}
Expand description
A basic event.
Required Associated Types
sourcetype Content: Debug + for<'a> Deserialize<'a> + Serialize
type Content: Debug + for<'a> Deserialize<'a> + Serialize
The event-type-specific payload this event carries.
Required Methods
sourcefn event_type(&self) -> &EventType
fn event_type(&self) -> &EventType
The type of the event.