pub struct ToolExecutionInterceptOutcome {
pub result: Value,
pub pending_marks: Vec<PendingMarkSpec>,
}Expand description
Canonical result returned by a tool execution intercept.
result is passed to the remaining middleware and application. pending_marks
are Relay-owned lifecycle metadata retained separately and emitted after the
tool-end event; they are not included in the application-visible result.
Fields§
§result: ValueTool result returned to the remaining middleware and application.
pending_marks: Vec<PendingMarkSpec>Ordered marks for the managed tool lifecycle owner to emit.
Implementations§
Source§impl ToolExecutionInterceptOutcome
impl ToolExecutionInterceptOutcome
Sourcepub fn new(result: Value) -> ToolExecutionInterceptOutcome
pub fn new(result: Value) -> ToolExecutionInterceptOutcome
Create an outcome without pending marks.
Sourcepub fn with_pending_mark(
self,
mark: PendingMarkSpec,
) -> ToolExecutionInterceptOutcome
pub fn with_pending_mark( self, mark: PendingMarkSpec, ) -> ToolExecutionInterceptOutcome
Append one pending mark while preserving callback order.
Trait Implementations§
Source§impl Clone for ToolExecutionInterceptOutcome
impl Clone for ToolExecutionInterceptOutcome
Source§fn clone(&self) -> ToolExecutionInterceptOutcome
fn clone(&self) -> ToolExecutionInterceptOutcome
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<'de> Deserialize<'de> for ToolExecutionInterceptOutcome
impl<'de> Deserialize<'de> for ToolExecutionInterceptOutcome
Source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<ToolExecutionInterceptOutcome, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<ToolExecutionInterceptOutcome, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl From<Value> for ToolExecutionInterceptOutcome
impl From<Value> for ToolExecutionInterceptOutcome
Source§fn from(result: Value) -> ToolExecutionInterceptOutcome
fn from(result: Value) -> ToolExecutionInterceptOutcome
Converts to this type from the input type.
Source§impl PartialEq for ToolExecutionInterceptOutcome
impl PartialEq for ToolExecutionInterceptOutcome
Source§fn eq(&self, other: &ToolExecutionInterceptOutcome) -> bool
fn eq(&self, other: &ToolExecutionInterceptOutcome) -> bool
Tests for
self and other values to be equal, and is used by ==.Source§impl Serialize for ToolExecutionInterceptOutcome
impl Serialize for ToolExecutionInterceptOutcome
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 ToolExecutionInterceptOutcome
Auto Trait Implementations§
impl Freeze for ToolExecutionInterceptOutcome
impl RefUnwindSafe for ToolExecutionInterceptOutcome
impl Send for ToolExecutionInterceptOutcome
impl Sync for ToolExecutionInterceptOutcome
impl Unpin for ToolExecutionInterceptOutcome
impl UnsafeUnpin for ToolExecutionInterceptOutcome
impl UnwindSafe for ToolExecutionInterceptOutcome
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