Package org.eclipse.lsp4j
Class ColorPresentation
- java.lang.Object
-
- org.eclipse.lsp4j.ColorPresentation
-
public class ColorPresentation extends java.lang.Object
Since 3.6.0
-
-
Constructor Summary
Constructors Constructor Description ColorPresentation()
ColorPresentation(java.lang.String label)
ColorPresentation(java.lang.String label, TextEdit textEdit)
ColorPresentation(java.lang.String label, TextEdit textEdit, java.util.List<TextEdit> additionalTextEdits)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
equals(java.lang.Object obj)
java.util.List<TextEdit>
getAdditionalTextEdits()
An optional array of additional text edits that are applied when selecting this color presentation.java.lang.String
getLabel()
The label of this color presentation.TextEdit
getTextEdit()
An edit which is applied to a document when selecting this presentation for the color.int
hashCode()
void
setAdditionalTextEdits(java.util.List<TextEdit> additionalTextEdits)
An optional array of additional text edits that are applied when selecting this color presentation.void
setLabel(java.lang.String label)
The label of this color presentation.void
setTextEdit(TextEdit textEdit)
An edit which is applied to a document when selecting this presentation for the color.java.lang.String
toString()
-
-
-
Constructor Detail
-
ColorPresentation
public ColorPresentation()
-
ColorPresentation
public ColorPresentation(java.lang.String label)
-
ColorPresentation
public ColorPresentation(java.lang.String label, TextEdit textEdit)
-
-
Method Detail
-
getLabel
public java.lang.String getLabel()
The label of this color presentation. It will be shown on the color picker header. By default this is also the text that is inserted when selecting this color presentation.
-
setLabel
public void setLabel(java.lang.String label)
The label of this color presentation. It will be shown on the color picker header. By default this is also the text that is inserted when selecting this color presentation.
-
getTextEdit
public TextEdit getTextEdit()
An edit which is applied to a document when selecting this presentation for the color. When `null` the label is used.
-
setTextEdit
public void setTextEdit(TextEdit textEdit)
An edit which is applied to a document when selecting this presentation for the color. When `null` the label is used.
-
getAdditionalTextEdits
public java.util.List<TextEdit> getAdditionalTextEdits()
An optional array of additional text edits that are applied when selecting this color presentation. Edits must not overlap with the main edit nor with themselves.
-
setAdditionalTextEdits
public void setAdditionalTextEdits(java.util.List<TextEdit> additionalTextEdits)
An optional array of additional text edits that are applied when selecting this color presentation. Edits must not overlap with the main edit nor with themselves.
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
-
equals
public boolean equals(java.lang.Object obj)
- Overrides:
equals
in classjava.lang.Object
-
hashCode
public int hashCode()
- Overrides:
hashCode
in classjava.lang.Object
-
-