UNPKG

712 BTypeScriptView Raw
1import { ExecuteCommandParams, ServerCapabilities } from "../languageclient";
2import { LanguageClientConnection } from "../main";
3export declare type CommandCustomCallbackFunction = (command: ExecuteCommandParams) => Promise<any | void>;
4export default class CommandExecutionAdapter {
5 private static commandsCustomCallbacks;
6 static canAdapt(serverCapabilities: ServerCapabilities): boolean;
7 static registerCustomCallbackForCommand(command: string, callback: CommandCustomCallbackFunction): void;
8 /** Returns a {Promise} */
9 static executeCommand(connection: LanguageClientConnection, command: string, commandArgs?: any[]): Promise<any | void>;
10 private static createExecuteCommandParams;
11}