Search in sources :

Example 16 with DidOpenTextDocumentParams

use of org.eclipse.lsp4j.DidOpenTextDocumentParams in project sts4 by spring-projects.

the class LanguageServerHarness method openDocument.

public TextDocumentInfo openDocument(TextDocumentInfo documentInfo) throws Exception {
    DidOpenTextDocumentParams didOpen = new DidOpenTextDocumentParams();
    didOpen.setTextDocument(documentInfo.getDocument());
    if (getServer() != null) {
        getServer().getTextDocumentService().didOpen(didOpen);
    }
    return documentInfo;
}
Also used : DidOpenTextDocumentParams(org.eclipse.lsp4j.DidOpenTextDocumentParams)

Aggregations

DidOpenTextDocumentParams (org.eclipse.lsp4j.DidOpenTextDocumentParams)16 TextDocumentItem (org.eclipse.lsp4j.TextDocumentItem)11 Test (org.junit.Test)10 Iterables (com.google.common.collect.Iterables)1 Lists (com.google.common.collect.Lists)1 Gson (com.google.gson.Gson)1 File (java.io.File)1 List (java.util.List)1 CompletableFuture (java.util.concurrent.CompletableFuture)1 ExecutionException (java.util.concurrent.ExecutionException)1 BallerinaLanguageServer (org.ballerinalang.langserver.BallerinaLanguageServer)1 TextDocumentIdentifier (org.eclipse.lsp4j.TextDocumentIdentifier)1 TextDocumentPositionParams (org.eclipse.lsp4j.TextDocumentPositionParams)1 Endpoint (org.eclipse.lsp4j.jsonrpc.Endpoint)1 ResponseError (org.eclipse.lsp4j.jsonrpc.messages.ResponseError)1 ResponseMessage (org.eclipse.lsp4j.jsonrpc.messages.ResponseMessage)1 ServiceEndpoints (org.eclipse.lsp4j.jsonrpc.services.ServiceEndpoints)1 TestLangLSPExtension (org.eclipse.xtext.ide.tests.testlanguage.ide.TestLangLSPExtension)1 TextOfLineParam (org.eclipse.xtext.ide.tests.testlanguage.ide.TestLangLSPExtension.TextOfLineParam)1 TextOfLineResult (org.eclipse.xtext.ide.tests.testlanguage.ide.TestLangLSPExtension.TextOfLineResult)1