export interface TaskHandle {
    readonly id: number;
    cancel(): void;
    readonly cancelled: boolean;
}
export declare class TaskQueue {
    private queue;
    private nextId;
    enqueue(task: () => void | Promise<void>): TaskHandle;
    get size(): number;
    flush(): Promise<void>;
}
//# sourceMappingURL=TaskQueue.d.ts.map