Outline with JDT LS LightWeight mode
This commit is contained in:
@@ -4,11 +4,17 @@
|
||||
import * as VSCode from 'vscode';
|
||||
import { RequestType } from 'vscode-languageclient';
|
||||
import { LanguageClient } from 'vscode-languageclient/node';
|
||||
import { workspace } from 'vscode';
|
||||
|
||||
export function registerClasspathService(client : LanguageClient) : void {
|
||||
|
||||
let addRequest = new RequestType<ClasspathListenerParams, ClasspathListenerResponse, void>("sts/addClasspathListener");
|
||||
client.onRequest(addRequest, async (params: ClasspathListenerParams) => {
|
||||
const jdtConfig = workspace.getConfiguration('java')
|
||||
const launchMode = jdtConfig?.get('server.launchMode');
|
||||
if (launchMode === 'LightWeight') {
|
||||
throw new Error('Classpath listener not supported while Java Language Server is in LightWeight mode');
|
||||
}
|
||||
return <ClasspathListenerResponse> await VSCode.commands.executeCommand("java.execute.workspaceCommand", "sts.java.addClasspathListener", params.callbackCommandId);
|
||||
});
|
||||
|
||||
|
||||
@@ -15,4 +15,5 @@ src/test/resources/test-projects/**/.classpath
|
||||
src/test/resources/test-projects/**/.project
|
||||
src/test/resources/test-projects/**/.factorypath
|
||||
src/test/resources/test-projects/**/.settings/**
|
||||
src/test/resources/test-projects/**/bin/**
|
||||
src/test/resources/test-projects/**/bin/**
|
||||
/package-lock.json
|
||||
|
||||
1757
vscode-extensions/vscode-spring-boot/package-lock.json
generated
1757
vscode-extensions/vscode-spring-boot/package-lock.json
generated
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user