import { type ExecutionDump, type GroupMeta, GroupedActionDump } from './types';
export interface IReportGenerator {
    /**
     * Write or update a single execution.
     * Each call appends a new dump script tag. The frontend deduplicates
     * executions with the same id/name, keeping only the last one.
     *
     * @param execution  Current execution's full data
     * @param groupMeta  Group-level metadata (groupName, sdkVersion, etc.)
     */
    onExecutionUpdate(execution: ExecutionDump, groupMeta: GroupMeta): void;
    /**
     * @deprecated Use onExecutionUpdate instead. Kept for backward compatibility.
     */
    onDumpUpdate?(dump: GroupedActionDump): void;
    /**
     * Wait for all queued write operations to complete.
     */
    flush(): Promise<void>;
    /**
     * Finalize the report. Calls flush() internally.
     */
    finalize(): Promise<string | undefined>;
    getReportPath(): string | undefined;
}
export declare const nullReportGenerator: IReportGenerator;
export declare class ReportGenerator implements IReportGenerator {
    private reportPath;
    private screenshotMode;
    private autoPrint;
    private firstWriteDone;
    private readonly reportStreamId;
    private writtenScreenshots;
    private initialized;
    private lastExecution?;
    private lastGroupMeta?;
    private writeQueue;
    private destroyed;
    constructor(options: {
        reportPath: string;
        screenshotMode: 'inline' | 'directory';
        autoPrint?: boolean;
    });
    static create(reportFileName: string, opts: {
        generateReport?: boolean;
        outputFormat?: 'single-html' | 'html-and-external-assets';
        autoPrintReportMsg?: boolean;
    }): IReportGenerator;
    onExecutionUpdate(execution: ExecutionDump, groupMeta: GroupMeta): void;
    flush(): Promise<void>;
    finalize(): Promise<string | undefined>;
    getReportPath(): string | undefined;
    private printReportPath;
    private doWriteExecution;
    /**
     * Wrap an ExecutionDump + GroupMeta into a single-execution GroupedActionDump.
     */
    private wrapAsGroupedDump;
    /**
     * Append-only inline mode: write new screenshots and a dump tag on every call.
     * The frontend deduplicates executions with the same id/name (keeps last).
     * Duplicate dump JSON is acceptable; only screenshots are deduplicated.
     */
    private writeInlineExecution;
    private writeDirectoryExecution;
}
