import { Observable } from 'rxjs';
import { CybIpfsNode } from '../ipfs/ipfs';
import { ParticleCid } from '../types/base';
import type { QueueItem, QueueItemCallback, QueueItemOptions, QueueStats, EnqueuedIpfsResult, IDeferredDbSaver } from './types';
import { QueueStrategy } from './QueueStrategy';
type QueueMap = Map<ParticleCid, QueueItem>;
declare class QueueManager {
    private queue$;
    private node;
    private defferedDbSaver?;
    private strategy;
    private queueDebounceMs;
    private lastNodeCallTime;
    private channel;
    private executing;
    private switchStrategy;
    setNode(node: CybIpfsNode, customStrategy?: QueueStrategy): Promise<void>;
    private getItemBySourceAndPriority;
    private postSummary;
    private fetchData$;
    private mutateQueueItem;
    private removeAndNext;
    private switchSourceAndNext;
    private cancelDeprioritizedItems;
    private releaseExecution;
    constructor(ipfsInstance$: Observable<CybIpfsNode | undefined>, { strategy, queueDebounceMs, defferedDbSaver, }: {
        strategy?: QueueStrategy;
        queueDebounceMs?: number;
        defferedDbSaver?: IDeferredDbSaver;
    });
    enqueue(cid: string, callback: QueueItemCallback, options?: QueueItemOptions): void;
    enqueueAndWait(cid: string, options?: QueueItemOptions): Promise<EnqueuedIpfsResult>;
    updateViewPortPriority(cid: string, viewPortPriority: number): void;
    cancel(cid: string): void;
    cancelByParent(parent: string): void;
    clear(): void;
    getQueueMap(): QueueMap;
    getQueueList(): QueueItem[];
    getStats(): QueueStats[];
}
export default QueueManager;
