/**
 * Tool Error Boundary Component
 *
 * Specialized error boundary for catching and handling tool execution errors.
 * Provides detailed error information and retry capabilities for tool failures.
 */
import React, { Component, ErrorInfo, ReactNode } from 'react';
interface ToolErrorBoundaryProps {
    children: ReactNode;
    toolName?: string;
    onRetry?: () => void;
    onError?: (error: Error, errorInfo: ErrorInfo) => void;
    maxRetries?: number;
    showDetails?: boolean;
}
interface ToolErrorBoundaryState {
    hasError: boolean;
    error: Error | null;
    errorInfo: ErrorInfo | null;
    retryCount: number;
    isRetrying: boolean;
}
/**
 * Error types specific to tool execution
 */
export declare enum ToolErrorType {
    EXECUTION_FAILED = "EXECUTION_FAILED",
    INVALID_PARAMETERS = "INVALID_PARAMETERS",
    TIMEOUT = "TIMEOUT",
    PERMISSION_DENIED = "PERMISSION_DENIED",
    RESOURCE_NOT_FOUND = "RESOURCE_NOT_FOUND",
    UNKNOWN = "UNKNOWN"
}
/**
 * Tool Error Boundary for handling tool execution errors
 */
export declare class ToolErrorBoundary extends Component<ToolErrorBoundaryProps, ToolErrorBoundaryState> {
    private retryTimeout;
    constructor(props: ToolErrorBoundaryProps);
    static getDerivedStateFromError(error: Error): Partial<ToolErrorBoundaryState>;
    componentDidCatch(error: Error, errorInfo: ErrorInfo): void;
    componentWillUnmount(): void;
    handleRetry: () => void;
    getErrorMessage(): string;
    render(): ReactNode;
}
/**
 * Hook to wrap components with Tool Error Boundary
 */
interface WithToolErrorBoundaryOptions {
    toolName?: string;
    onRetry?: () => void;
    onError?: (error: Error, errorInfo: ErrorInfo) => void;
    maxRetries?: number;
    showDetails?: boolean;
}
export declare function withToolErrorBoundary<P extends object>(WrappedComponent: React.ComponentType<P>, options?: WithToolErrorBoundaryOptions): React.FC<P>;
export default ToolErrorBoundary;
