pub struct RunErrorEvent {
pub base: BaseEvent,
pub message: String,
pub code: Option<String>,
}Expand description
Event indicating that a run has encountered an error.
This event is sent when an agent run fails with an error.
Fields§
§base: BaseEventCommon event fields (timestamp, rawEvent).
message: StringError message describing what went wrong.
code: Option<String>Optional error code for programmatic handling.
Implementations§
Source§impl RunErrorEvent
impl RunErrorEvent
Sourcepub fn new(message: impl Into<String>) -> RunErrorEvent
pub fn new(message: impl Into<String>) -> RunErrorEvent
Creates a new RunErrorEvent.
Sourcepub fn with_code(self, code: impl Into<String>) -> RunErrorEvent
pub fn with_code(self, code: impl Into<String>) -> RunErrorEvent
Sets the error code.
Sourcepub fn with_timestamp(self, timestamp: f64) -> RunErrorEvent
pub fn with_timestamp(self, timestamp: f64) -> RunErrorEvent
Sets the timestamp for this event.
Trait Implementations§
Source§impl Clone for RunErrorEvent
impl Clone for RunErrorEvent
Source§fn clone(&self) -> RunErrorEvent
fn clone(&self) -> RunErrorEvent
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 RunErrorEvent
impl Debug for RunErrorEvent
Source§impl<'de> Deserialize<'de> for RunErrorEvent
impl<'de> Deserialize<'de> for RunErrorEvent
Source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<RunErrorEvent, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<RunErrorEvent, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl PartialEq for RunErrorEvent
impl PartialEq for RunErrorEvent
Source§impl Serialize for RunErrorEvent
impl Serialize for RunErrorEvent
Source§fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
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
impl StructuralPartialEq for RunErrorEvent
Auto Trait Implementations§
impl Freeze for RunErrorEvent
impl RefUnwindSafe for RunErrorEvent
impl Send for RunErrorEvent
impl Sync for RunErrorEvent
impl Unpin for RunErrorEvent
impl UnsafeUnpin for RunErrorEvent
impl UnwindSafe for RunErrorEvent
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