Class CodeActionContext
java.lang.Object
org.graalvm.tools.lsp.server.types.JSONBase
org.graalvm.tools.lsp.server.types.CodeActionContext
Contains additional diagnostic information about the context in which a [code
action](#CodeActionProvider.provideCodeActions) is run.
-
Method Summary
Modifier and TypeMethodDescriptionstatic CodeActionContextcreate(List<Diagnostic> diagnostics, List<CodeActionKind> only) Creates a new CodeActionContext literal.booleanAn array of diagnostics known on the client side overlapping the range provided to the `textDocument/codeAction` request.getOnly()Requested kind of actions to return.inthashCode()setDiagnostics(List<Diagnostic> diagnostics) setOnly(List<CodeActionKind> only)
-
Method Details
-
getDiagnostics
An array of diagnostics known on the client side overlapping the range provided to the `textDocument/codeAction` request. They are provied so that the server knows which errors are currently presented to the user for the given range. There is no guarantee that these accurately reflect the error state of the resource. The primary parameter to compute code actions is the provided range. -
setDiagnostics
-
getOnly
Requested kind of actions to return. Actions not of this kind are filtered out by the client before being shown. So servers can omit computing them. -
setOnly
-
equals
-
hashCode
public int hashCode() -
create
Creates a new CodeActionContext literal.
-