/** * REPL Command Parser * * Parses and executes commands in the REPL shell */ /** * Parsed command */ export interface ParsedCommand { raw: string; name: string; args: string[]; flags: Record; } /** * Command result */ export interface CommandResult { success: boolean; output?: string; error?: string; data?: unknown; } /** * Command definition */ export interface CommandDefinition { name: string; aliases?: string[]; description: string; usage: string; examples: string[]; handler: (args: string[], flags: Record) => Promise; completions?: (args: string[]) => string[]; } /** * REPL Command Parser */ export declare class REPLCommandParser { private commands; private aliases; constructor(); /** * Register a command */ registerCommand(def: CommandDefinition): void; /** * Unregister a command */ unregisterCommand(name: string): void; /** * Parse a command string */ parse(input: string): ParsedCommand | null; /** * Execute a parsed command */ execute(parsed: ParsedCommand): Promise; /** * Get command completions */ getCompletions(input: string, cursor: number): string[]; /** * Get all command names */ getCommandNames(): string[]; /** * Get command definition */ getCommand(name: string): CommandDefinition | undefined; /** * Get help text for a command */ getHelp(name?: string): string; /** * Group commands by category */ private groupCommandsByCategory; /** * Register default commands */ private registerDefaultCommands; } //# sourceMappingURL=parser.d.ts.map