#[non_exhaustive]pub struct DelayedEventData {
pub delay_id: String,
pub room_id: OwnedRoomId,
pub event_type: TimelineEventType,
pub state_key: Option<String>,
pub content: Raw<AnyTimelineEventContent>,
pub delay: Duration,
pub running_since: MilliSecondsSinceUnixEpoch,
pub error: Option<StandardErrorBody>,
pub event_id: Option<OwnedEventId>,
pub finalized_ts: Option<MilliSecondsSinceUnixEpoch>,
}api and crate feature unstable-msc4140 and (crate features client-api-c or client-api-s) and (crate features client or server) only.Expand description
The structure of the data for returning a delayed event from a GET endpoint
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.delay_id: StringThe ID of the delayed event.
room_id: OwnedRoomIdThe ID of the room that the delayed event was scheduled to be sent in.
event_type: TimelineEventTypeThe event type of the delayed event.
state_key: Option<String>The State Key if the event is a state event, nothing otherwise
content: Raw<AnyTimelineEventContent>The event content to send.
This is the content that was submitted to the send endpoint, not the content of the final event
delay: DurationThe duration that the server should wait before sending this event
running_since: MilliSecondsSinceUnixEpochThe timestamp when the delayed event was scheduled or last restarted.
error: Option<StandardErrorBody>The error that prevented the delayed event from being sent. Present only for finalized events that were cancelled due to an error.
event_id: Option<OwnedEventId>The event_id this event got when it was sent. Present only for events that were sent successfully.
finalized_ts: Option<MilliSecondsSinceUnixEpoch>The timestamp when the event was finalized. Present only for events that were finalized (sent, failed to send, or cancelled).
Implementations§
Source§impl DelayedEventData
impl DelayedEventData
Sourcepub fn new(
delay_id: String,
room_id: OwnedRoomId,
event_type: TimelineEventType,
state_key: Option<String>,
content: Raw<AnyTimelineEventContent>,
delay: Duration,
running_since: MilliSecondsSinceUnixEpoch,
) -> DelayedEventData
pub fn new( delay_id: String, room_id: OwnedRoomId, event_type: TimelineEventType, state_key: Option<String>, content: Raw<AnyTimelineEventContent>, delay: Duration, running_since: MilliSecondsSinceUnixEpoch, ) -> DelayedEventData
Create a new delayed event data object with the given parameters
Sourcepub fn status(&self) -> DelayedEventStatus
pub fn status(&self) -> DelayedEventStatus
Returns the status indicated by this delayed event data.
Trait Implementations§
Source§impl Clone for DelayedEventData
impl Clone for DelayedEventData
Source§fn clone(&self) -> DelayedEventData
fn clone(&self) -> DelayedEventData
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more