/**
 * Unified Task Executor
 *
 * Consolidates multiple task management components into a single, cohesive executor:
 * - TaskLauncher (launch tasks)
 * - TaskPoller (monitor tasks)
 * - TaskCleaner (cleanup tasks)
 * - TaskResumer (resume tasks)
 * - EventHandler (handle events)
 *
 * This reduces complexity from 5 separate components to 1 unified executor.
 */
import type { PluginInput } from "@opencode-ai/plugin";
import type { ParallelTask } from "./interfaces/parallel-task.interface.js";
import type { LaunchInput } from "./interfaces/launch-input.interface.js";
import type { ResumeInput } from "./interfaces/resume-input.interface.js";
import { TaskStore } from "./task-store.js";
import { ConcurrencyController } from "./concurrency.js";
import { SessionPool } from "./session-pool.js";
type OpencodeClient = PluginInput["client"];
/**
 * Unified Task Executor
 *
 * Combines all task management responsibilities into one cohesive class.
 */
export declare class UnifiedTaskExecutor {
    private client;
    private directory;
    private store;
    private concurrency;
    private sessionPool;
    private pollInterval;
    private isPolling;
    private cleanupTimers;
    constructor(client: OpencodeClient, directory: string, store: TaskStore, concurrency: ConcurrencyController, sessionPool: SessionPool);
    /**
     * Launch a new parallel task
     */
    launch(input: LaunchInput): Promise<ParallelTask>;
    /**
     * Start polling for task updates
     */
    private startPolling;
    /**
     * Stop polling
     */
    private stopPolling;
    /**
     * Poll all running tasks
     */
    private pollTasks;
    /**
     * Poll a single task
     */
    private pollTask;
    /**
     * Handle task completion
     */
    private handleTaskComplete;
    /**
     * Handle task error
     */
    private handleTaskError;
    /**
     * Schedule cleanup for a task
     */
    private scheduleCleanup;
    /**
     * Cleanup a task
     */
    private cleanupTask;
    /**
     * Prune expired tasks
     */
    private pruneExpiredTasks;
    /**
     * Notify parent if all tasks complete
     */
    private notifyParentIfAllComplete;
    /**
     * Resume a task from disk
     */
    resume(input: ResumeInput): Promise<ParallelTask | null>;
    /**
     * Recover all active tasks from disk
     */
    recoverAll(): Promise<number>;
    /**
     * Cancel a task
     */
    cancel(taskId: string): Promise<boolean>;
    /**
     * Get task by ID
     */
    getTask(taskId: string): ParallelTask | undefined;
    /**
     * Get all tasks
     */
    getAllTasks(): ParallelTask[];
    /**
     * Get tasks by parent
     */
    getTasksByParent(parentSessionID: string): ParallelTask[];
    /**
     * Cleanup all resources
     */
    cleanup(): void;
}
export {};
