pub enum ToolErrorKind {
NotFound,
Timeout,
Network,
PermissionDenied,
InvalidInput,
RateLimited,
LoopDetected,
Internal,
}Expand description
工具执行错误的分类。
Variants§
NotFound
工具未找到
Timeout
工具执行超时
Network
网络相关错误
PermissionDenied
权限不足
InvalidInput
输入参数无效
RateLimited
被限流
LoopDetected
检测到循环调用
Internal
内部错误(兜底)
Implementations§
Source§impl ToolErrorKind
impl ToolErrorKind
Sourcepub fn is_retriable(self) -> bool
pub fn is_retriable(self) -> bool
该错误类型是否值得重试
Trait Implementations§
Source§impl Clone for ToolErrorKind
impl Clone for ToolErrorKind
Source§fn clone(&self) -> ToolErrorKind
fn clone(&self) -> ToolErrorKind
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 moreimpl Copy for ToolErrorKind
Source§impl Debug for ToolErrorKind
impl Debug for ToolErrorKind
Source§impl Display for ToolErrorKind
impl Display for ToolErrorKind
impl Eq for ToolErrorKind
Source§impl PartialEq for ToolErrorKind
impl PartialEq for ToolErrorKind
Source§fn eq(&self, other: &ToolErrorKind) -> bool
fn eq(&self, other: &ToolErrorKind) -> bool
Tests for
self and other values to be equal, and is used by ==.impl StructuralPartialEq for ToolErrorKind
Auto Trait Implementations§
impl Freeze for ToolErrorKind
impl RefUnwindSafe for ToolErrorKind
impl Send for ToolErrorKind
impl Sync for ToolErrorKind
impl Unpin for ToolErrorKind
impl UnsafeUnpin for ToolErrorKind
impl UnwindSafe for ToolErrorKind
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