Enum ruma::events::AnySyncRoomEvent [−][src]
pub enum AnySyncRoomEvent {
Message(AnySyncMessageEvent),
State(AnySyncStateEvent),
RedactedMessage(AnyRedactedSyncMessageEvent),
RedactedState(AnyRedactedSyncStateEvent),
}
events
only.Expand description
Any sync room event (room event without a room_id
, as returned in /sync
responses)
Variants
Message(AnySyncMessageEvent)
Any sync message event
State(AnySyncStateEvent)
Any sync state event
RedactedMessage(AnyRedactedSyncMessageEvent)
Any sync message event that has been redacted.
RedactedState(AnyRedactedSyncStateEvent)
Any sync state event that has been redacted.
Implementations
Returns this event’s origin_server_ts
field.
Converts self
to an AnyRoomEvent
by adding the given a room ID.
Trait Implementations
pub fn deserialize<D>(
deserializer: D
) -> Result<AnySyncRoomEvent, <D as Deserializer<'de>>::Error> where
D: Deserializer<'de>,
pub fn deserialize<D>(
deserializer: D
) -> Result<AnySyncRoomEvent, <D as Deserializer<'de>>::Error> where
D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Performs the conversion.
Performs the conversion.
Performs the conversion.
Performs the conversion.
Performs the conversion.
pub fn redact(
self,
redaction: SyncRedactionEvent,
version: &RoomVersionId
) -> <AnySyncRoomEvent as Redact>::Redacted
pub fn redact(
self,
redaction: SyncRedactionEvent,
version: &RoomVersionId
) -> <AnySyncRoomEvent as Redact>::Redacted
Redacts self
, referencing the given event in unsigned.redacted_because
.
Does nothing for events that are already redacted.
type Redacted = AnyRedactedSyncRoomEvent
type Redacted = AnyRedactedSyncRoomEvent
The redacted form of the event.
pub fn serialize<__S>(
&self,
__serializer: __S
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error> where
__S: Serializer,
pub fn serialize<__S>(
&self,
__serializer: __S
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error> where
__S: Serializer,
Serialize this value into the given Serde serializer. Read more
Auto Trait Implementations
impl RefUnwindSafe for AnySyncRoomEvent
impl Send for AnySyncRoomEvent
impl Sync for AnySyncRoomEvent
impl Unpin for AnySyncRoomEvent
impl UnwindSafe for AnySyncRoomEvent
Blanket Implementations
Mutably borrows from an owned value. Read more
Instruments this type with the provided Span
, returning an
Instrumented
wrapper. Read more
Instruments this type with the provided Span
, returning an
Instrumented
wrapper. Read more
type Output = T
type Output = T
Should always be Self
pub fn vzip(self) -> V
Attaches the provided Subscriber
to this type, returning a
WithDispatch
wrapper. Read more
Attaches the current default Subscriber
to this type, returning a
WithDispatch
wrapper. Read more