Class DocumentLink

java.lang.Object
org.graalvm.tools.lsp.server.types.JSONBase
org.graalvm.tools.lsp.server.types.DocumentLink

public class DocumentLink extends JSONBase
A document link is a range in a text document that links to an internal or external resource, like another text document or a web site.
  • Method Details

    • getRange

      public Range getRange()
      The range this link applies to.
    • setRange

      public DocumentLink setRange(Range range)
    • getTarget

      public String getTarget()
      The uri this link points to.
    • setTarget

      public DocumentLink setTarget(String target)
    • getTooltip

      public String getTooltip()
      The tooltip text when you hover over this link. If a tooltip is provided, is will be displayed in a string that includes instructions on how to trigger the link, such as `{0} (ctrl + click)`. The specific instructions vary depending on OS, user settings, and localization.
      Since:
      3.15.0
    • setTooltip

      public DocumentLink setTooltip(String tooltip)
    • getData

      public Object getData()
      A data entry field that is preserved on a document link between a DocumentLinkRequest and a DocumentLinkResolveRequest.
    • setData

      public DocumentLink setData(Object data)
    • equals

      public boolean equals(Object obj)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • create

      public static DocumentLink create(Range range, String target, Object data)
      Creates a new DocumentLink literal.