MCPcopy Create free account
hub / github.com/microsoft/vscode-languageserver-node / _RemoteWorkspaceImpl

Class _RemoteWorkspaceImpl

server/src/main.ts:811–841  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

809export type RemoteWorkspace = _RemoteWorkspace & Configuration & WorkspaceFolders;
810
811class _RemoteWorkspaceImpl implements _RemoteWorkspace {
812
813 private _connection: IConnection;
814
815 public constructor() {
816 }
817
818 public attach(connection: IConnection) {
819 this._connection = connection;
820 }
821
822 public get connection(): IConnection {
823 if (!this._connection) {
824 throw new Error('Remote is not attached to a connection yet.');
825 }
826 return this._connection;
827 }
828
829 public initialize(_capabilities: ClientCapabilities): void {
830 }
831
832 public fillServerCapabilities(_capabilities: ServerCapabilities): void {
833 }
834
835 public applyEdit(edit: WorkspaceEdit): Thenable<ApplyWorkspaceEditResponse> {
836 let params: ApplyWorkspaceEditParams = {
837 edit
838 };
839 return this._connection.sendRequest(ApplyWorkspaceEditRequest.type, params);
840 }
841}
842
843const RemoteWorkspaceImpl: new () => RemoteWorkspace = WorkspaceFoldersFeature(ConfigurationFeature(_RemoteWorkspaceImpl)) as (new () => RemoteWorkspace);
844

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected