export declare const DEFAULT_QUEUE_CONCURRENCY = 10; export interface YQueueOptions { concurrency?: number; } export interface EnqueueOptions { priority: number; } export declare type Task = (() => PromiseLike) | (() => TaskResultType); export declare class YQueue { readonly options?: YQueueOptions | undefined; private readonly semaphore; readonly concurrency: number; private onIdleWaits; private onQueueLessThanWaits; constructor(options?: YQueueOptions | undefined); run(fn: Task, options?: Partial): Promise; add(fn: Task, options?: Partial): void; onIdle(): Promise; onQueueSizeLessThan(size: number): Promise; } export default YQueue;