import type { ExecutionContext, TypedExecutionContext } from '../../types/core';
import type { ASTNode, ExpressionNode } from '../../types/base-types';
import type { ExpressionEvaluator } from '../../core/expression-evaluator';
import { type DecoratedCommand, type CommandMetadata } from '../decorators';
export type ConditionalMode = 'if' | 'unless';
export interface ConditionalCommandInput {
    mode: ConditionalMode;
    condition: unknown;
    thenCommands: ASTNode | ASTNode[];
    elseCommands?: ASTNode | ASTNode[];
}
export interface IfCommandInput extends ConditionalCommandInput {
}
export interface UnlessCommandInput {
    condition: unknown;
    commands: ASTNode[];
}
export interface ConditionalCommandOutput {
    mode: ConditionalMode;
    conditionResult: boolean;
    executedBranch: 'then' | 'else' | 'none';
    result: unknown;
}
export interface IfCommandOutput extends ConditionalCommandOutput {
}
export declare class ConditionalCommand implements DecoratedCommand {
    readonly name: string;
    readonly metadata: CommandMetadata;
    parseInput(raw: {
        args: ASTNode[];
        modifiers: Record<string, ExpressionNode>;
        commandName?: string;
    }, evaluator: ExpressionEvaluator, context: ExecutionContext): Promise<ConditionalCommandInput>;
    execute(input: ConditionalCommandInput, context: TypedExecutionContext): Promise<ConditionalCommandOutput>;
    private executeCommandsOrBlock;
    private executeBlock;
    private executeCommands;
}
export declare const createConditionalCommand: () => ConditionalCommand;
export { ConditionalCommand as IfCommand };
export declare const createIfCommand: () => ConditionalCommand;
export { ConditionalCommand as UnlessCommand };
export declare const createUnlessCommand: () => ConditionalCommand;
export default ConditionalCommand;
//# sourceMappingURL=if.d.ts.map