import { Document } from 'bson'; import { CancellationToken, TypedEventEmitter } from '../mongo_types'; import type { QpSessionPause as QpSessionPause } from './session-pause'; /** @public */ export declare type QpPauseEvents = { 'mongodb:pause': () => void; 'mongodb:resume': () => void; }; /** @public */ export declare type QpPausePhase = 'pre' | 'post'; /** @public */ export declare type QpPauseContext = { id: string; command: Document; result: Document | undefined; phase: QpPausePhase; /** @internal */ _session: QpSessionPause; }; /** @public */ export declare class QpPause extends TypedEventEmitter { static kNoPause: string; private readonly _queue; private _current; private readonly logger; /** @internal */ _isCommandCapturing: boolean; get isCommandCapturing(): boolean; start(): void; stop(): void; abort(): void; resume(updatedDocument: Document | undefined): void; wait(token: CancellationToken): Promise; /** @internal */ waitEvent(event: K, token: CancellationToken): Promise; /** @internal */ pause(pause: QpSessionPause, phase: QpPausePhase, command: Document, result: Document | undefined): void; private tryRaisePause; private static _instance; static get instance(): QpPause; } //# sourceMappingURL=pause.d.ts.map