/** * Storage-specific errors for LearnGraph * * @packageDocumentation */ /** * Base error class for storage operations */ export declare class StorageError extends Error { readonly code: string; readonly cause?: Error | undefined; constructor(message: string, code: string, cause?: Error | undefined); } /** * Thrown when connection to storage backend fails */ export declare class ConnectionError extends StorageError { constructor(message: string, cause?: Error); } /** * Thrown when attempting operation without active connection */ export declare class NotConnectedError extends StorageError { constructor(); } /** * Thrown when a skill or edge is not found */ export declare class NotFoundError extends StorageError { readonly entityType: 'skill' | 'edge'; readonly entityId: string; constructor(entityType: 'skill' | 'edge', entityId: string); } /** * Thrown when attempting to create a duplicate entity */ export declare class DuplicateError extends StorageError { readonly entityType: 'skill' | 'edge'; readonly entityId: string; constructor(entityType: 'skill' | 'edge', entityId: string); } /** * Thrown when edge references non-existent skill */ export declare class ReferenceError extends StorageError { readonly edgeId: string; readonly missingSkillId: string; readonly role: 'source' | 'target'; constructor(edgeId: string, missingSkillId: string, role: 'source' | 'target'); } /** * Thrown when data validation fails */ export declare class ValidationError extends StorageError { readonly field?: string | undefined; readonly value?: unknown | undefined; constructor(message: string, field?: string | undefined, value?: unknown | undefined); } /** * Thrown when a query times out */ export declare class TimeoutError extends StorageError { readonly operation: string; readonly timeoutMs: number; constructor(operation: string, timeoutMs: number); } /** * Thrown when a cycle is detected in the graph */ export declare class CycleDetectedError extends StorageError { readonly path: string[]; constructor(path: string[]); } //# sourceMappingURL=errors.d.ts.map