Trait matrix_sdk::ruma::events::EventContentFromType
pub trait EventContentFromType: EventContent {
// Required method
fn from_parts(event_type: &str, content: &RawValue) -> Result<Self, Error>;
}
Expand description
Event content that can be deserialized with its event type.
Required Methods§
fn from_parts(event_type: &str, content: &RawValue) -> Result<Self, Error>
fn from_parts(event_type: &str, content: &RawValue) -> Result<Self, Error>
Constructs this event content from the given event type and JSON.
Object Safety§
This trait is not object safe.