pub struct EventTimeline {
pub events: Vec<ExecutionEvent>,
}Expand description
Event timeline for an execution
Fields§
§events: Vec<ExecutionEvent>All events in chronological order
Implementations§
Source§impl EventTimeline
impl EventTimeline
Sourcepub fn push(&mut self, event: ExecutionEvent)
pub fn push(&mut self, event: ExecutionEvent)
Add an event to the timeline
Sourcepub fn filter_by_type(&self, event_type: EventType) -> Vec<&ExecutionEvent>
pub fn filter_by_type(&self, event_type: EventType) -> Vec<&ExecutionEvent>
Get events by type
Sourcepub fn filter_by_node(&self, node_id: NodeId) -> Vec<&ExecutionEvent>
pub fn filter_by_node(&self, node_id: NodeId) -> Vec<&ExecutionEvent>
Get events by node
Sourcepub fn filter_by_time_range(
&self,
start: DateTime<Utc>,
end: DateTime<Utc>,
) -> Vec<&ExecutionEvent>
pub fn filter_by_time_range( &self, start: DateTime<Utc>, end: DateTime<Utc>, ) -> Vec<&ExecutionEvent>
Get events in time range
Sourcepub fn total_duration_ms(&self) -> Option<u64>
pub fn total_duration_ms(&self) -> Option<u64>
Get total execution duration in milliseconds
Sourcepub fn count_by_type(&self, event_type: EventType) -> usize
pub fn count_by_type(&self, event_type: EventType) -> usize
Count events by type
Sourcepub fn errors(&self) -> Vec<&ExecutionEvent>
pub fn errors(&self) -> Vec<&ExecutionEvent>
Get all error events
Sourcepub fn is_successful(&self) -> bool
pub fn is_successful(&self) -> bool
Check if execution was successful
Trait Implementations§
Source§impl Clone for EventTimeline
impl Clone for EventTimeline
Source§fn clone(&self) -> EventTimeline
fn clone(&self) -> EventTimeline
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for EventTimeline
impl Debug for EventTimeline
Source§impl Default for EventTimeline
impl Default for EventTimeline
Source§fn default() -> EventTimeline
fn default() -> EventTimeline
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for EventTimeline
impl<'de> Deserialize<'de> for EventTimeline
Source§fn 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
Auto Trait Implementations§
impl Freeze for EventTimeline
impl RefUnwindSafe for EventTimeline
impl Send for EventTimeline
impl Sync for EventTimeline
impl Unpin for EventTimeline
impl UnwindSafe for EventTimeline
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more