pub struct ToolContext<M: InputSender> {
pub message_sender: M,
pub group_id: ThreadId,
pub callback_url: String,
pub user_id: Option<String>,
pub thread_stack: Vec<ThreadId>,
}Expand description
Context passed to tool implementations — generic over platform backends.
Fields§
§message_sender: M§group_id: ThreadId§callback_url: String§user_id: Option<String>§thread_stack: Vec<ThreadId>Full thread stack: [root, ..ancestors, current_thread].
Trait Implementations§
Source§impl<M: Clone + InputSender> Clone for ToolContext<M>
impl<M: Clone + InputSender> Clone for ToolContext<M>
Source§fn clone(&self) -> ToolContext<M>
fn clone(&self) -> ToolContext<M>
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 moreAuto Trait Implementations§
impl<M> Freeze for ToolContext<M>where
M: Freeze,
impl<M> RefUnwindSafe for ToolContext<M>where
M: RefUnwindSafe,
impl<M> Send for ToolContext<M>
impl<M> Sync for ToolContext<M>
impl<M> Unpin for ToolContext<M>where
M: Unpin,
impl<M> UnsafeUnpin for ToolContext<M>where
M: UnsafeUnpin,
impl<M> UnwindSafe for ToolContext<M>where
M: UnwindSafe,
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