pub enum MailboxMessage {
Started {
agent_id: String,
agent_type: String,
},
Progress {
agent_id: String,
status: String,
},
ToolCallStarted {
agent_id: String,
tool_name: String,
step: u32,
},
ToolCallCompleted {
agent_id: String,
tool_name: String,
step: u32,
ok: bool,
},
ChildSpawned {
parent_id: String,
child_id: String,
},
Completed {
agent_id: String,
summary: String,
},
Failed {
agent_id: String,
error: String,
},
Cancelled {
agent_id: String,
},
TokenUsage {
agent_id: String,
model: String,
usage: Usage,
},
}Variants§
Started
Progress
ToolCallStarted
ToolCallCompleted
ChildSpawned
Completed
Failed
Cancelled
TokenUsage
Implementations§
Source§impl MailboxMessage
impl MailboxMessage
pub fn started(agent_id: impl Into<String>, agent_type: impl AsRef<str>) -> Self
pub fn progress(agent_id: impl Into<String>, status: impl Into<String>) -> Self
pub fn token_usage( agent_id: impl Into<String>, model: impl Into<String>, usage: Usage, ) -> Self
pub fn agent_id(&self) -> &str
Trait Implementations§
Source§impl Clone for MailboxMessage
impl Clone for MailboxMessage
Source§fn clone(&self) -> MailboxMessage
fn clone(&self) -> MailboxMessage
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · 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 MailboxMessage
impl Debug for MailboxMessage
Source§impl<'de> Deserialize<'de> for MailboxMessage
impl<'de> Deserialize<'de> for MailboxMessage
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
impl Eq for MailboxMessage
Source§impl PartialEq for MailboxMessage
impl PartialEq for MailboxMessage
Source§fn eq(&self, other: &MailboxMessage) -> bool
fn eq(&self, other: &MailboxMessage) -> bool
Tests for
self and other values to be equal, and is used by ==.Source§impl Serialize for MailboxMessage
impl Serialize for MailboxMessage
impl StructuralPartialEq for MailboxMessage
Auto Trait Implementations§
impl Freeze for MailboxMessage
impl RefUnwindSafe for MailboxMessage
impl Send for MailboxMessage
impl Sync for MailboxMessage
impl Unpin for MailboxMessage
impl UnsafeUnpin for MailboxMessage
impl UnwindSafe for MailboxMessage
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