Class InlayHint


  • public class InlayHint
    extends java.lang.Object
    Inlay hint information.

    Since 3.17.0

    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      boolean equals​(java.lang.Object obj)  
      java.lang.Object getData()
      A data entry field that is preserved on a inlay hint between a textDocument/inlayHint and a inlayHint/resolve request.
      InlayHintKind getKind()
      The kind of this hint.
      org.eclipse.lsp4j.jsonrpc.messages.Either<java.lang.String,​java.util.List<InlayHintLabelPart>> getLabel()
      The label of this hint.
      java.lang.Boolean getPaddingLeft()
      Render padding before the hint.
      java.lang.Boolean getPaddingRight()
      Render padding after the hint.
      Position getPosition()
      The position of this hint.
      java.util.List<TextEdit> getTextEdits()
      Optional text edits that are performed when accepting this inlay hint.
      org.eclipse.lsp4j.jsonrpc.messages.Either<java.lang.String,​MarkupContent> getTooltip()
      The tooltip text when you hover over this item.
      int hashCode()  
      void setData​(java.lang.Object data)
      A data entry field that is preserved on a inlay hint between a textDocument/inlayHint and a inlayHint/resolve request.
      void setKind​(InlayHintKind kind)
      The kind of this hint.
      void setLabel​(java.lang.String label)  
      void setLabel​(java.util.List<InlayHintLabelPart> label)  
      void setLabel​(org.eclipse.lsp4j.jsonrpc.messages.Either<java.lang.String,​java.util.List<InlayHintLabelPart>> label)
      The label of this hint.
      void setPaddingLeft​(java.lang.Boolean paddingLeft)
      Render padding before the hint.
      void setPaddingRight​(java.lang.Boolean paddingRight)
      Render padding after the hint.
      void setPosition​(Position position)
      The position of this hint.
      void setTextEdits​(java.util.List<TextEdit> textEdits)
      Optional text edits that are performed when accepting this inlay hint.
      void setTooltip​(java.lang.String tooltip)  
      void setTooltip​(org.eclipse.lsp4j.jsonrpc.messages.Either<java.lang.String,​MarkupContent> tooltip)
      The tooltip text when you hover over this item.
      void setTooltip​(MarkupContent tooltip)  
      java.lang.String toString()  
      • Methods inherited from class java.lang.Object

        clone, finalize, getClass, notify, notifyAll, wait, wait, wait
    • Constructor Detail

      • InlayHint

        public InlayHint()
      • InlayHint

        public InlayHint​(Position position,
                         org.eclipse.lsp4j.jsonrpc.messages.Either<java.lang.String,​java.util.List<InlayHintLabelPart>> label)
    • Method Detail

      • getPosition

        public Position getPosition()
        The position of this hint.
      • setPosition

        public void setPosition​(Position position)
        The position of this hint.
      • getLabel

        public org.eclipse.lsp4j.jsonrpc.messages.Either<java.lang.String,​java.util.List<InlayHintLabelPart>> getLabel()
        The label of this hint. A human readable string or an array of InlayHintLabelPart label parts.

        *Note* that neither the string nor the label part can be empty.

      • setLabel

        public void setLabel​(org.eclipse.lsp4j.jsonrpc.messages.Either<java.lang.String,​java.util.List<InlayHintLabelPart>> label)
        The label of this hint. A human readable string or an array of InlayHintLabelPart label parts.

        *Note* that neither the string nor the label part can be empty.

      • setLabel

        public void setLabel​(java.lang.String label)
      • getKind

        public InlayHintKind getKind()
        The kind of this hint. Can be omitted in which case the client should fall back to a reasonable default.
      • setKind

        public void setKind​(InlayHintKind kind)
        The kind of this hint. Can be omitted in which case the client should fall back to a reasonable default.
      • getTextEdits

        public java.util.List<TextEdit> getTextEdits()
        Optional text edits that are performed when accepting this inlay hint.

        *Note* that edits are expected to change the document so that the inlay hint (or its nearest variant) is now part of the document and the inlay hint itself is now obsolete.

        Depending on the client capability InlayHintCapabilities.resolveSupport clients might resolve this property late using the resolve request.

      • setTextEdits

        public void setTextEdits​(java.util.List<TextEdit> textEdits)
        Optional text edits that are performed when accepting this inlay hint.

        *Note* that edits are expected to change the document so that the inlay hint (or its nearest variant) is now part of the document and the inlay hint itself is now obsolete.

        Depending on the client capability InlayHintCapabilities.resolveSupport clients might resolve this property late using the resolve request.

      • getTooltip

        public org.eclipse.lsp4j.jsonrpc.messages.Either<java.lang.String,​MarkupContent> getTooltip()
        The tooltip text when you hover over this item.

        Depending on the client capability InlayHintCapabilities.resolveSupport clients might resolve this property late using the resolve request.

      • setTooltip

        public void setTooltip​(org.eclipse.lsp4j.jsonrpc.messages.Either<java.lang.String,​MarkupContent> tooltip)
        The tooltip text when you hover over this item.

        Depending on the client capability InlayHintCapabilities.resolveSupport clients might resolve this property late using the resolve request.

      • setTooltip

        public void setTooltip​(java.lang.String tooltip)
      • getPaddingLeft

        public java.lang.Boolean getPaddingLeft()
        Render padding before the hint.

        Note: Padding should use the editor's background color, not the background color of the hint itself. That means padding can be used to visually align/separate an inlay hint.

      • setPaddingLeft

        public void setPaddingLeft​(java.lang.Boolean paddingLeft)
        Render padding before the hint.

        Note: Padding should use the editor's background color, not the background color of the hint itself. That means padding can be used to visually align/separate an inlay hint.

      • getPaddingRight

        public java.lang.Boolean getPaddingRight()
        Render padding after the hint.

        Note: Padding should use the editor's background color, not the background color of the hint itself. That means padding can be used to visually align/separate an inlay hint.

      • setPaddingRight

        public void setPaddingRight​(java.lang.Boolean paddingRight)
        Render padding after the hint.

        Note: Padding should use the editor's background color, not the background color of the hint itself. That means padding can be used to visually align/separate an inlay hint.

      • getData

        public java.lang.Object getData()
        A data entry field that is preserved on a inlay hint between a textDocument/inlayHint and a inlayHint/resolve request.
      • setData

        public void setData​(java.lang.Object data)
        A data entry field that is preserved on a inlay hint between a textDocument/inlayHint and a inlayHint/resolve request.
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object
      • equals

        public boolean equals​(java.lang.Object obj)
        Overrides:
        equals in class java.lang.Object
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class java.lang.Object