pub struct CancellationToken { /* private fields */ }Expand description
Shared cancellation signal for an agent run.
Cancellation is observed at operation boundaries. A model request or tool invocation that has already started is allowed to finish; its result is recorded before the runtime stops. No subsequent model or tool operation is started after cancellation is observed. This avoids abandoning a tool result when an external side effect may already have occurred.
Implementations§
Trait Implementations§
Source§impl Clone for CancellationToken
impl Clone for CancellationToken
Auto Trait Implementations§
impl Freeze for CancellationToken
impl RefUnwindSafe for CancellationToken
impl Send for CancellationToken
impl Sync for CancellationToken
impl Unpin for CancellationToken
impl UnsafeUnpin for CancellationToken
impl UnwindSafe for CancellationToken
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