Package org.eclipse.lsp4j
Class CodeActionDisabled
- java.lang.Object
-
- org.eclipse.lsp4j.CodeActionDisabled
-
public class CodeActionDisabled extends java.lang.ObjectMarks that the code action cannot currently be applied.Clients should follow the following guidelines regarding disabled code actions:
- Disabled code actions are not shown in automatic lightbulb code action menu.
- Disabled actions are shown as faded out in the code action menu when the user request a more specific type of code action, such as refactorings.
- If the user has a keybinding
that auto applies a code action and only a disabled code actions are returned, the client should show the user an
error message with
reasonin the editor.
Since 3.16.0
-
-
Constructor Summary
Constructors Constructor Description CodeActionDisabled()CodeActionDisabled(java.lang.String reason)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanequals(java.lang.Object obj)java.lang.StringgetReason()Human readable description of why the code action is currently disabled.inthashCode()voidsetReason(java.lang.String reason)Human readable description of why the code action is currently disabled.java.lang.StringtoString()
-
-
-
Method Detail
-
getReason
public java.lang.String getReason()
Human readable description of why the code action is currently disabled.This is displayed in the code actions UI.
-
setReason
public void setReason(java.lang.String reason)
Human readable description of why the code action is currently disabled.This is displayed in the code actions UI.
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
equals
public boolean equals(java.lang.Object obj)
- Overrides:
equalsin classjava.lang.Object
-
hashCode
public int hashCode()
- Overrides:
hashCodein classjava.lang.Object
-
-