import { IRPCProtocol } from '@opensumi/ide-connection';
import { StaticResourceService } from '@opensumi/ide-core-browser/lib/static-resource';
import { ILineChange, IRange, ISelection, WithEventBus } from '@opensumi/ide-core-common';
import { IDecorationApplyOptions, IDecorationRenderOptions, IResourceOpenOptions, ISingleEditOperation, IUndoStopOptions } from '@opensumi/ide-editor';
import { IEditorChangeDTO, IEditorStatusChangeDTO, IMainThreadEditorsService, ITextEditorUpdateConfiguration, TextEditorCursorStyle, TextEditorRevealType } from '../../../common/vscode';
import { EndOfLineSequence } from '../../../common/vscode/models';
import { MainThreadExtensionDocumentData } from './main.thread.doc';
import type { ICodeEditor as IMonacoCodeEditor } from '@opensumi/ide-monaco/lib/browser/monaco-api/types';
export declare class MainThreadEditorService extends WithEventBus implements IMainThreadEditorsService {
    private rpcProtocol;
    private documents;
    private readonly editorService;
    private readonly decorationService;
    private readonly codeEditorService;
    staticResourceService: StaticResourceService;
    private readonly proxy;
    constructor(rpcProtocol: IRPCProtocol, documents: MainThreadExtensionDocumentData);
    $getInitialState(): Promise<IEditorChangeDTO>;
    $closeEditor(id: string): Promise<void>;
    $revealRange(id: string, range: IRange, type?: TextEditorRevealType): Promise<void>;
    $createTextEditorDecorationType(key: string, options: IDecorationRenderOptions): Promise<void>;
    private resolveIconPaths;
    $deleteTextEditorDecorationType(key: string): Promise<void>;
    $applyDecoration(id: string, decorationKey: string, options: IDecorationApplyOptions[]): Promise<void>;
    $insertSnippet(id: string, snippet: string, ranges?: IRange[], options?: IUndoStopOptions): Promise<void>;
    $updateOptions(id: string, update: ITextEditorUpdateConfiguration): Promise<void>;
    private getEditor;
    private getGroup;
    protected propertiesChangeCache: Map<string, IEditorStatusChangeDTO>;
    triggerPropertiesChange: import("lodash").DebouncedFunc<() => void>;
    /**
     * 按 id 缓存 change, 每次 change 都会合并到缓存中，debounce 发送给插件进程
     */
    protected batchPropertiesChanges(change: Partial<IEditorStatusChangeDTO> & {
        id: string;
    }): void;
    startEvents(): void;
    private acceptCurrentEditor;
    $applyEdits(id: string, documentVersionId: number, edits: ISingleEditOperation[], options: {
        setEndOfLine: EndOfLineSequence | undefined;
        undoStopBefore: boolean;
        undoStopAfter: boolean;
    }): Promise<boolean>;
    $openResource(uri: string, options: IResourceOpenOptions): Promise<string>;
    $setSelections(id: string, selections: ISelection[]): Promise<void>;
    setConfiguration(codeEditor: IMonacoCodeEditor, newConfiguration: ITextEditorUpdateConfiguration): void;
    $getDiffInformation(id: string): Promise<ILineChange[]>;
    private _setIndentConfiguration;
}
export declare function cursorStyleToString(cursorStyle: TextEditorCursorStyle): string;
//# sourceMappingURL=main.thread.editor.d.ts.map