pub enum ToolExecutionOutcome {
Completed(ToolResult),
Interrupted(ToolInterruption),
Failed(ToolError),
}Expand description
The three-way result of a ToolExecutor::execute call.
Unlike a simple Result, this type distinguishes between a successful
completion, an interruption requiring user input (approval or auth), and
an outright failure.
Variants§
Completed(ToolResult)
The tool ran to completion and produced a result.
Interrupted(ToolInterruption)
The tool was interrupted and needs user input before it can continue.
Failed(ToolError)
The tool failed with an error.
Trait Implementations§
Source§impl Clone for ToolExecutionOutcome
impl Clone for ToolExecutionOutcome
Source§fn clone(&self) -> ToolExecutionOutcome
fn clone(&self) -> ToolExecutionOutcome
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 ToolExecutionOutcome
impl Debug for ToolExecutionOutcome
Source§impl<'de> Deserialize<'de> for ToolExecutionOutcome
impl<'de> Deserialize<'de> for ToolExecutionOutcome
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
Source§impl PartialEq for ToolExecutionOutcome
impl PartialEq for ToolExecutionOutcome
Source§impl Serialize for ToolExecutionOutcome
impl Serialize for ToolExecutionOutcome
impl StructuralPartialEq for ToolExecutionOutcome
Auto Trait Implementations§
impl Freeze for ToolExecutionOutcome
impl RefUnwindSafe for ToolExecutionOutcome
impl Send for ToolExecutionOutcome
impl Sync for ToolExecutionOutcome
impl Unpin for ToolExecutionOutcome
impl UnsafeUnpin for ToolExecutionOutcome
impl UnwindSafe for ToolExecutionOutcome
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