import { IRPCProtocol } from '@opensumi/ide-connection';
import { CommandRegistry, IContextKeyService, IDisposable, ILogger } from '@opensumi/ide-core-browser';
import { IExtensionInfo } from '@opensumi/ide-core-common';
import { IMonacoCommandService } from '@opensumi/ide-monaco/lib/browser/contrib/command';
import { ArgumentProcessor, IMainThreadCommands } from '../../../common/vscode';
export interface IExtCommandHandler extends IDisposable {
    execute: (...args: any[]) => Promise<any>;
}
export declare class MainThreadCommands implements IMainThreadCommands {
    #private;
    private rpcProtocol;
    private readonly commands;
    protected readonly argumentProcessors: ArgumentProcessor[];
    commandRegistry: CommandRegistry;
    monacoCommandService: IMonacoCommandService;
    logger: ILogger;
    protected contextKeyService: IContextKeyService;
    private disposable;
    constructor(rpcProtocol: IRPCProtocol);
    private registerUriArgProcessor;
    dispose(): void;
    registerArgumentProcessor(processor: ArgumentProcessor): IDisposable;
    $registerCommand(id: string): void;
    $unregisterCommand(id: string): void;
    $getCommands(): Promise<string[]>;
    /**
     * 来自main -> extHost的command调用
     */
    $executeExtensionCommand(id: string, ...args: any[]): Promise<any>;
    $executeCommandWithExtensionInfo<T>(id: string, extensionInfo: IExtensionInfo, ...args: any[]): Promise<T | undefined>;
    $executeCommand<T>(id: string, ...args: any[]): Promise<T | undefined>;
}
//# sourceMappingURL=main.thread.commands.d.ts.map