pub struct SearchTool { /* private fields */ }Expand description
Web search tool with built-in and MCP support
Implementations§
Source§impl SearchTool
impl SearchTool
Sourcepub fn validate_query(query: &str) -> Result<(), ToolError>
pub fn validate_query(query: &str) -> Result<(), ToolError>
Validate search query for injection attacks and format
Sourcepub async fn search(&self, input: SearchInput) -> ToolResult<SearchOutput>
pub async fn search(&self, input: SearchInput) -> ToolResult<SearchOutput>
Execute a web search with MCP fallback to built-in
Trait Implementations§
Auto Trait Implementations§
impl Freeze for SearchTool
impl !RefUnwindSafe for SearchTool
impl Send for SearchTool
impl Sync for SearchTool
impl Unpin for SearchTool
impl !UnwindSafe for SearchTool
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