pub struct ToolAttemptHandoff { /* private fields */ }Expand description
Retained tool-attempt handoff safe to retry before physical dispatch.
Implementations§
Source§impl ToolAttemptHandoff
impl ToolAttemptHandoff
Sourcepub fn new(
fence: RunFence,
invocation: ToolInvocation,
attempt_id: AttemptId,
events: InvocationAttemptEventIds,
cancellation: CancellationSignal,
progress_sink: Option<Arc<dyn ToolProgressSink>>,
) -> Result<Self, InvocationAttemptHandoffError>
pub fn new( fence: RunFence, invocation: ToolInvocation, attempt_id: AttemptId, events: InvocationAttemptEventIds, cancellation: CancellationSignal, progress_sink: Option<Arc<dyn ToolProgressSink>>, ) -> Result<Self, InvocationAttemptHandoffError>
Constructs and scope-checks one tool attempt handoff.
§Errors
Rejects crossed scope or a non-startable durable invocation state.
Sourcepub const fn invocation(&self) -> &ToolInvocation
pub const fn invocation(&self) -> &ToolInvocation
Returns the prepared or safely retryable durable invocation revision.
Sourcepub const fn attempt_id(&self) -> AttemptId
pub const fn attempt_id(&self) -> AttemptId
Returns the proposed unique physical tool attempt.
Sourcepub const fn events(&self) -> InvocationAttemptEventIds
pub const fn events(&self) -> InvocationAttemptEventIds
Returns stable start/terminal journal identities.
Trait Implementations§
Source§impl Clone for ToolAttemptHandoff
impl Clone for ToolAttemptHandoff
Auto Trait Implementations§
impl !RefUnwindSafe for ToolAttemptHandoff
impl !UnwindSafe for ToolAttemptHandoff
impl Forget for ToolAttemptHandoff
impl Freeze for ToolAttemptHandoff
impl Move for ToolAttemptHandoff
impl Send for ToolAttemptHandoff
impl Sync for ToolAttemptHandoff
impl Unpin for ToolAttemptHandoff
impl UnsafeUnpin for ToolAttemptHandoff
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more