-
Notifications
You must be signed in to change notification settings - Fork 108
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Вынос описания расширений протокола в отдельный интерфейс
- Loading branch information
Showing
3 changed files
with
54 additions
and
18 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
42 changes: 42 additions & 0 deletions
42
src/main/java/com/github/_1c_syntax/bsl/languageserver/jsonrpc/ProtocolExtension.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
/* | ||
* This file is a part of BSL Language Server. | ||
* | ||
* Copyright © 2018-2020 | ||
* Alexey Sosnoviy <[email protected]>, Nikita Gryzlov <[email protected]> and contributors | ||
* | ||
* SPDX-License-Identifier: LGPL-3.0-or-later | ||
* | ||
* BSL Language Server is free software; you can redistribute it and/or | ||
* modify it under the terms of the GNU Lesser General Public | ||
* License as published by the Free Software Foundation; either | ||
* version 3.0 of the License, or (at your option) any later version. | ||
* | ||
* BSL Language Server is distributed in the hope that it will be useful, | ||
* but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | ||
* Lesser General Public License for more details. | ||
* | ||
* You should have received a copy of the GNU Lesser General Public | ||
* License along with BSL Language Server. | ||
*/ | ||
package com.github._1c_syntax.bsl.languageserver.jsonrpc; | ||
|
||
import org.eclipse.lsp4j.Diagnostic; | ||
import org.eclipse.lsp4j.jsonrpc.services.JsonRequest; | ||
|
||
import java.util.List; | ||
import java.util.concurrent.CompletableFuture; | ||
|
||
public interface ProtocolExtension { | ||
|
||
/** | ||
* @param params Параметры запроса. | ||
* @return Список диагностик. | ||
*/ | ||
@JsonRequest( | ||
value = "textDocument/x-diagnostics", | ||
useSegment = false | ||
) | ||
CompletableFuture<List<Diagnostic>> diagnostics(DiagnosticParams params); | ||
|
||
} |