pub enum AnySyncMessageLikeEvent {
Show 26 variants
Audio(SyncAudioEvent),
CallAnswer(SyncCallAnswerEvent),
CallInvite(SyncCallInviteEvent),
CallHangup(SyncCallHangupEvent),
CallCandidates(SyncCallCandidatesEvent),
Emote(SyncEmoteEvent),
File(SyncFileEvent),
Image(SyncImageEvent),
KeyVerificationReady(SyncKeyVerificationReadyEvent),
KeyVerificationStart(SyncKeyVerificationStartEvent),
KeyVerificationCancel(SyncKeyVerificationCancelEvent),
KeyVerificationAccept(SyncKeyVerificationAcceptEvent),
KeyVerificationKey(SyncKeyVerificationKeyEvent),
KeyVerificationMac(SyncKeyVerificationMacEvent),
KeyVerificationDone(SyncKeyVerificationDoneEvent),
Location(SyncLocationEvent),
Message(SyncMessageEvent),
Notice(SyncNoticeEvent),
Reaction(SyncReactionEvent),
RoomEncrypted(SyncRoomEncryptedEvent),
RoomMessage(SyncRoomMessageEvent),
RoomMessageFeedback(SyncRoomMessageFeedbackEvent),
RoomRedaction(SyncRoomRedactionEvent),
Sticker(SyncStickerEvent),
Video(SyncVideoEvent),
Voice(SyncVoiceEvent),
// some variants omitted
}events only.Expand description
Any message-like event.
Variants
Audio(SyncAudioEvent)
unstable-msc3246 only.m.audio
CallAnswer(SyncCallAnswerEvent)
m.call.answer
CallInvite(SyncCallInviteEvent)
m.call.invite
CallHangup(SyncCallHangupEvent)
m.call.hangup
CallCandidates(SyncCallCandidatesEvent)
m.call.candidates
Emote(SyncEmoteEvent)
unstable-msc1767 only.m.emote
File(SyncFileEvent)
unstable-msc3551 only.m.file
Image(SyncImageEvent)
unstable-msc3552 only.m.image
KeyVerificationReady(SyncKeyVerificationReadyEvent)
m.key.verification.ready
KeyVerificationStart(SyncKeyVerificationStartEvent)
m.key.verification.start
KeyVerificationCancel(SyncKeyVerificationCancelEvent)
m.key.verification.cancel
KeyVerificationAccept(SyncKeyVerificationAcceptEvent)
m.key.verification.accept
KeyVerificationKey(SyncKeyVerificationKeyEvent)
m.key.verification.key
KeyVerificationMac(SyncKeyVerificationMacEvent)
m.key.verification.mac
KeyVerificationDone(SyncKeyVerificationDoneEvent)
m.key.verification.done
Location(SyncLocationEvent)
unstable-msc3488 only.m.location
Message(SyncMessageEvent)
unstable-msc1767 only.m.message
Notice(SyncNoticeEvent)
unstable-msc1767 only.m.notice
Reaction(SyncReactionEvent)
unstable-msc2677 only.m.reaction
RoomEncrypted(SyncRoomEncryptedEvent)
m.room.encrypted
RoomMessage(SyncRoomMessageEvent)
m.room.message
RoomMessageFeedback(SyncRoomMessageFeedbackEvent)
m.room.message.feedback
RoomRedaction(SyncRoomRedactionEvent)
m.room.redaction
Sticker(SyncStickerEvent)
m.sticker
Video(SyncVideoEvent)
unstable-msc3553 only.m.video
Voice(SyncVoiceEvent)
unstable-msc3245 only.m.voice
Implementations
sourceimpl AnySyncMessageLikeEvent
impl AnySyncMessageLikeEvent
sourcepub fn event_type(&self) -> MessageLikeEventType
pub fn event_type(&self) -> MessageLikeEventType
Returns the type of this event.
sourcepub fn original_content(&self) -> Option<AnyMessageLikeEventContent>
pub fn original_content(&self) -> Option<AnyMessageLikeEventContent>
Returns the content for this event if it is not redacted, or None if it is.
sourcepub fn origin_server_ts(&self) -> MilliSecondsSinceUnixEpoch
pub fn origin_server_ts(&self) -> MilliSecondsSinceUnixEpoch
Returns this event’s origin_server_ts field.
sourcepub fn transaction_id(&self) -> Option<&TransactionId>
pub fn transaction_id(&self) -> Option<&TransactionId>
Returns this event’s transaction_id from inside unsigned, if there is one.
sourceimpl AnySyncMessageLikeEvent
impl AnySyncMessageLikeEvent
sourcepub fn into_full_event(self, room_id: OwnedRoomId) -> AnyMessageLikeEvent
pub fn into_full_event(self, room_id: OwnedRoomId) -> AnyMessageLikeEvent
Convert this sync event into a full event (one with a room_id field).
Trait Implementations
sourceimpl Clone for AnySyncMessageLikeEvent
impl Clone for AnySyncMessageLikeEvent
sourcefn clone(&self) -> AnySyncMessageLikeEvent
fn clone(&self) -> AnySyncMessageLikeEvent
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read more
sourceimpl Debug for AnySyncMessageLikeEvent
impl Debug for AnySyncMessageLikeEvent
sourceimpl<'de> Deserialize<'de> for AnySyncMessageLikeEvent
impl<'de> Deserialize<'de> for AnySyncMessageLikeEvent
sourcefn deserialize<D>(deserializer: D) -> Result<Self, D::Error> where
D: Deserializer<'de>,
fn deserialize<D>(deserializer: D) -> Result<Self, D::Error> where
D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
sourceimpl From<AnyMessageLikeEvent> for AnySyncMessageLikeEvent
impl From<AnyMessageLikeEvent> for AnySyncMessageLikeEvent
sourcefn from(event: AnyMessageLikeEvent) -> Self
fn from(event: AnyMessageLikeEvent) -> Self
Converts to this type from the input type.
sourceimpl From<AnySyncMessageLikeEvent> for AnySyncRoomEvent
impl From<AnySyncMessageLikeEvent> for AnySyncRoomEvent
sourcefn from(c: AnySyncMessageLikeEvent) -> Self
fn from(c: AnySyncMessageLikeEvent) -> Self
Converts to this type from the input type.
sourceimpl From<SyncMessageLikeEvent<AudioEventContent>> for AnySyncMessageLikeEvent
Available on crate feature unstable-msc3246 only.
impl From<SyncMessageLikeEvent<AudioEventContent>> for AnySyncMessageLikeEvent
unstable-msc3246 only.sourcefn from(c: SyncAudioEvent) -> Self
fn from(c: SyncAudioEvent) -> Self
Converts to this type from the input type.
sourceimpl From<SyncMessageLikeEvent<CallAnswerEventContent>> for AnySyncMessageLikeEvent
impl From<SyncMessageLikeEvent<CallAnswerEventContent>> for AnySyncMessageLikeEvent
sourcefn from(c: SyncCallAnswerEvent) -> Self
fn from(c: SyncCallAnswerEvent) -> Self
Converts to this type from the input type.
sourceimpl From<SyncMessageLikeEvent<CallCandidatesEventContent>> for AnySyncMessageLikeEvent
impl From<SyncMessageLikeEvent<CallCandidatesEventContent>> for AnySyncMessageLikeEvent
sourcefn from(c: SyncCallCandidatesEvent) -> Self
fn from(c: SyncCallCandidatesEvent) -> Self
Converts to this type from the input type.
sourceimpl From<SyncMessageLikeEvent<CallHangupEventContent>> for AnySyncMessageLikeEvent
impl From<SyncMessageLikeEvent<CallHangupEventContent>> for AnySyncMessageLikeEvent
sourcefn from(c: SyncCallHangupEvent) -> Self
fn from(c: SyncCallHangupEvent) -> Self
Converts to this type from the input type.
sourceimpl From<SyncMessageLikeEvent<CallInviteEventContent>> for AnySyncMessageLikeEvent
impl From<SyncMessageLikeEvent<CallInviteEventContent>> for AnySyncMessageLikeEvent
sourcefn from(c: SyncCallInviteEvent) -> Self
fn from(c: SyncCallInviteEvent) -> Self
Converts to this type from the input type.
sourceimpl From<SyncMessageLikeEvent<EmoteEventContent>> for AnySyncMessageLikeEvent
Available on crate feature unstable-msc1767 only.
impl From<SyncMessageLikeEvent<EmoteEventContent>> for AnySyncMessageLikeEvent
unstable-msc1767 only.sourcefn from(c: SyncEmoteEvent) -> Self
fn from(c: SyncEmoteEvent) -> Self
Converts to this type from the input type.
sourceimpl From<SyncMessageLikeEvent<FileEventContent>> for AnySyncMessageLikeEvent
Available on crate feature unstable-msc3551 only.
impl From<SyncMessageLikeEvent<FileEventContent>> for AnySyncMessageLikeEvent
unstable-msc3551 only.sourcefn from(c: SyncFileEvent) -> Self
fn from(c: SyncFileEvent) -> Self
Converts to this type from the input type.
sourceimpl From<SyncMessageLikeEvent<ImageEventContent>> for AnySyncMessageLikeEvent
Available on crate feature unstable-msc3552 only.
impl From<SyncMessageLikeEvent<ImageEventContent>> for AnySyncMessageLikeEvent
unstable-msc3552 only.sourcefn from(c: SyncImageEvent) -> Self
fn from(c: SyncImageEvent) -> Self
Converts to this type from the input type.
sourceimpl From<SyncMessageLikeEvent<KeyVerificationAcceptEventContent>> for AnySyncMessageLikeEvent
impl From<SyncMessageLikeEvent<KeyVerificationAcceptEventContent>> for AnySyncMessageLikeEvent
sourcefn from(c: SyncKeyVerificationAcceptEvent) -> Self
fn from(c: SyncKeyVerificationAcceptEvent) -> Self
Converts to this type from the input type.
sourceimpl From<SyncMessageLikeEvent<KeyVerificationCancelEventContent>> for AnySyncMessageLikeEvent
impl From<SyncMessageLikeEvent<KeyVerificationCancelEventContent>> for AnySyncMessageLikeEvent
sourcefn from(c: SyncKeyVerificationCancelEvent) -> Self
fn from(c: SyncKeyVerificationCancelEvent) -> Self
Converts to this type from the input type.
sourceimpl From<SyncMessageLikeEvent<KeyVerificationDoneEventContent>> for AnySyncMessageLikeEvent
impl From<SyncMessageLikeEvent<KeyVerificationDoneEventContent>> for AnySyncMessageLikeEvent
sourcefn from(c: SyncKeyVerificationDoneEvent) -> Self
fn from(c: SyncKeyVerificationDoneEvent) -> Self
Converts to this type from the input type.
sourceimpl From<SyncMessageLikeEvent<KeyVerificationKeyEventContent>> for AnySyncMessageLikeEvent
impl From<SyncMessageLikeEvent<KeyVerificationKeyEventContent>> for AnySyncMessageLikeEvent
sourcefn from(c: SyncKeyVerificationKeyEvent) -> Self
fn from(c: SyncKeyVerificationKeyEvent) -> Self
Converts to this type from the input type.
sourceimpl From<SyncMessageLikeEvent<KeyVerificationMacEventContent>> for AnySyncMessageLikeEvent
impl From<SyncMessageLikeEvent<KeyVerificationMacEventContent>> for AnySyncMessageLikeEvent
sourcefn from(c: SyncKeyVerificationMacEvent) -> Self
fn from(c: SyncKeyVerificationMacEvent) -> Self
Converts to this type from the input type.
sourceimpl From<SyncMessageLikeEvent<KeyVerificationReadyEventContent>> for AnySyncMessageLikeEvent
impl From<SyncMessageLikeEvent<KeyVerificationReadyEventContent>> for AnySyncMessageLikeEvent
sourcefn from(c: SyncKeyVerificationReadyEvent) -> Self
fn from(c: SyncKeyVerificationReadyEvent) -> Self
Converts to this type from the input type.
sourceimpl From<SyncMessageLikeEvent<KeyVerificationStartEventContent>> for AnySyncMessageLikeEvent
impl From<SyncMessageLikeEvent<KeyVerificationStartEventContent>> for AnySyncMessageLikeEvent
sourcefn from(c: SyncKeyVerificationStartEvent) -> Self
fn from(c: SyncKeyVerificationStartEvent) -> Self
Converts to this type from the input type.
sourceimpl From<SyncMessageLikeEvent<LocationEventContent>> for AnySyncMessageLikeEvent
Available on crate feature unstable-msc3488 only.
impl From<SyncMessageLikeEvent<LocationEventContent>> for AnySyncMessageLikeEvent
unstable-msc3488 only.sourcefn from(c: SyncLocationEvent) -> Self
fn from(c: SyncLocationEvent) -> Self
Converts to this type from the input type.
sourceimpl From<SyncMessageLikeEvent<MessageEventContent>> for AnySyncMessageLikeEvent
Available on crate feature unstable-msc1767 only.
impl From<SyncMessageLikeEvent<MessageEventContent>> for AnySyncMessageLikeEvent
unstable-msc1767 only.sourcefn from(c: SyncMessageEvent) -> Self
fn from(c: SyncMessageEvent) -> Self
Converts to this type from the input type.
sourceimpl From<SyncMessageLikeEvent<NoticeEventContent>> for AnySyncMessageLikeEvent
Available on crate feature unstable-msc1767 only.
impl From<SyncMessageLikeEvent<NoticeEventContent>> for AnySyncMessageLikeEvent
unstable-msc1767 only.sourcefn from(c: SyncNoticeEvent) -> Self
fn from(c: SyncNoticeEvent) -> Self
Converts to this type from the input type.
sourceimpl From<SyncMessageLikeEvent<ReactionEventContent>> for AnySyncMessageLikeEvent
Available on crate feature unstable-msc2677 only.
impl From<SyncMessageLikeEvent<ReactionEventContent>> for AnySyncMessageLikeEvent
unstable-msc2677 only.sourcefn from(c: SyncReactionEvent) -> Self
fn from(c: SyncReactionEvent) -> Self
Converts to this type from the input type.
sourceimpl From<SyncMessageLikeEvent<RoomEncryptedEventContent>> for AnySyncMessageLikeEvent
impl From<SyncMessageLikeEvent<RoomEncryptedEventContent>> for AnySyncMessageLikeEvent
sourcefn from(c: SyncRoomEncryptedEvent) -> Self
fn from(c: SyncRoomEncryptedEvent) -> Self
Converts to this type from the input type.
sourceimpl From<SyncMessageLikeEvent<RoomMessageEventContent>> for AnySyncMessageLikeEvent
impl From<SyncMessageLikeEvent<RoomMessageEventContent>> for AnySyncMessageLikeEvent
sourcefn from(c: SyncRoomMessageEvent) -> Self
fn from(c: SyncRoomMessageEvent) -> Self
Converts to this type from the input type.
sourceimpl From<SyncMessageLikeEvent<RoomMessageFeedbackEventContent>> for AnySyncMessageLikeEvent
impl From<SyncMessageLikeEvent<RoomMessageFeedbackEventContent>> for AnySyncMessageLikeEvent
sourcefn from(c: SyncRoomMessageFeedbackEvent) -> Self
fn from(c: SyncRoomMessageFeedbackEvent) -> Self
Converts to this type from the input type.
sourceimpl From<SyncMessageLikeEvent<StickerEventContent>> for AnySyncMessageLikeEvent
impl From<SyncMessageLikeEvent<StickerEventContent>> for AnySyncMessageLikeEvent
sourcefn from(c: SyncStickerEvent) -> Self
fn from(c: SyncStickerEvent) -> Self
Converts to this type from the input type.
sourceimpl From<SyncMessageLikeEvent<VideoEventContent>> for AnySyncMessageLikeEvent
Available on crate feature unstable-msc3553 only.
impl From<SyncMessageLikeEvent<VideoEventContent>> for AnySyncMessageLikeEvent
unstable-msc3553 only.sourcefn from(c: SyncVideoEvent) -> Self
fn from(c: SyncVideoEvent) -> Self
Converts to this type from the input type.
sourceimpl From<SyncMessageLikeEvent<VoiceEventContent>> for AnySyncMessageLikeEvent
Available on crate feature unstable-msc3245 only.
impl From<SyncMessageLikeEvent<VoiceEventContent>> for AnySyncMessageLikeEvent
unstable-msc3245 only.sourcefn from(c: SyncVoiceEvent) -> Self
fn from(c: SyncVoiceEvent) -> Self
Converts to this type from the input type.
sourceimpl From<SyncRoomRedactionEvent> for AnySyncMessageLikeEvent
impl From<SyncRoomRedactionEvent> for AnySyncMessageLikeEvent
sourcefn from(c: SyncRoomRedactionEvent) -> Self
fn from(c: SyncRoomRedactionEvent) -> Self
Converts to this type from the input type.
sourceimpl Redact for AnySyncMessageLikeEvent
impl Redact for AnySyncMessageLikeEvent
type Redacted = AnySyncMessageLikeEvent
type Redacted = AnySyncMessageLikeEvent
events only.The redacted form of the event.
sourcefn redact(
self,
redaction: SyncRoomRedactionEvent,
version: &RoomVersionId
) -> Self
fn redact(
self,
redaction: SyncRoomRedactionEvent,
version: &RoomVersionId
) -> Self
events only.Transforms self into a redacted form (removing most fields) according to the spec. Read more
Auto Trait Implementations
impl RefUnwindSafe for AnySyncMessageLikeEvent
impl Send for AnySyncMessageLikeEvent
impl Sync for AnySyncMessageLikeEvent
impl Unpin for AnySyncMessageLikeEvent
impl UnwindSafe for AnySyncMessageLikeEvent
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> Instrument for T
impl<T> Instrument for T
sourcefn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
sourcefn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcefn clone_into(&self, target: &mut T)
fn clone_into(&self, target: &mut T)
toowned_clone_into)Uses borrowed data to replace owned data, usually by cloning. Read more
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
fn vzip(self) -> V
sourceimpl<T> WithSubscriber for T
impl<T> WithSubscriber for T
sourcefn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
Attaches the provided Subscriber to this type, returning a
WithDispatch wrapper. Read more
sourcefn with_current_subscriber(self) -> WithDispatch<Self>
fn with_current_subscriber(self) -> WithDispatch<Self>
Attaches the current default Subscriber to this type, returning a
WithDispatch wrapper. Read more
