import { Disposable, IDisposable } from "../../../../../../base/common/lifecycle.js"; import { IObservable, IReader, ITransaction } from "../../../../../../base/common/observable.js"; import { URI } from "../../../../../../base/common/uri.js"; import { IFileService } from "../../../../../../platform/files/common/files.service.js"; import { ILogService } from "../../../../../../platform/log/common/log.service.js"; import { IEditSessionEntryDiff } from "../../../common/editing/chatEditingService.js"; import type { IToolCallFileEdit } from "./stateToProgressAdapter.js"; export interface IAgentHostCheckpointReviewFile { readonly diff: IEditSessionEntryDiff; readonly nonce: string | undefined; } export interface IAgentHostCheckpointReviewSource { readonly channel: URI; readonly ready: boolean; readonly failed?: boolean; readonly files: readonly IAgentHostCheckpointReviewFile[]; } /** Excludes fully restored revisions during reversible checkpoint preview, without discarding host history. */ export declare class AgentHostCheckpointReview extends Disposable { private readonly _fileService; private readonly _logService; private readonly _sources; private readonly _restored; private readonly _lifetime; constructor(_fileService: IFileService, _logService: ILogService); registerSource(source: IObservable): IDisposable; project(channel: URI, files: readonly T[], reader?: IReader): readonly T[]; /** Prepares visibility for the affected resources, using cumulative history to recognize fully restored revisions. */ prepareRestore(checkpoints: readonly { readonly edits: readonly IToolCallFileEdit[]; }[], undo: boolean, affectedResources: readonly URI[]): Promise<(tx: ITransaction) => void>; private _whenReady; private _isContinuous; }