use of org.eclipse.lsp4j.ServerInfo in project OberonEmulator by schierlm.
the class Server method initialize.
@Override
public CompletableFuture<InitializeResult> initialize(InitializeParams params) {
ServerCapabilities cap = new ServerCapabilities();
fillCapabilities(cap, params);
ServerInfo si = new ServerInfo("Oberon Language Server", "0.1");
InitializeResult ir = new InitializeResult(cap, si);
return CompletableFuture.completedFuture(ir);
}
use of org.eclipse.lsp4j.ServerInfo in project kolmafia by kolmafia.
the class AshLanguageServer method initialize.
@Override
public CompletableFuture<InitializeResult> initialize(InitializeParams params) {
this.clientCapabilities = params.getCapabilities();
this.executor.execute(this.monitor::scan);
return CompletableFuture.supplyAsync(() -> {
final ServerCapabilities capabilities = new ServerCapabilities();
this.textDocumentService.setCapabilities(capabilities);
this.workspaceService.setCapabilities(capabilities);
final ServerInfo info = new ServerInfo(StaticEntity.getVersion());
return new InitializeResult(capabilities, info);
}, this.executor);
}
Aggregations