Interface LinkInfo

  • All Known Implementing Classes:
    InlineParserImpl.LinkInfoImpl

    public interface LinkInfo
    A parsed link/image. There are different types of links.

    Inline links:

     [text](destination)
     [text](destination "title")
     

    Reference links, which have different subtypes. Full::

     [text][label]
     
    Collapsed (label is ""):
     [text][]
     
    Shortcut (label is null):
     [text]
     
    Images use the same syntax as links but with a ! marker() front, e.g. ![text](destination).
    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      Position afterTextBracket()
      The position after the closing text bracket, e.g.:
      java.lang.String destination()
      The destination if available, e.g.
      java.lang.String label()
      The label, or null for inline links or for shortcut links (in which case text() should be used as the label).
      Text marker()
      The marker if present, or null.
      Text openingBracket()
      The text node of the opening bracket [.
      java.lang.String text()
      The text between the first brackets, e.g.
      java.lang.String title()
      The title if available, e.g.
    • Method Detail

      • openingBracket

        Text openingBracket()
        The text node of the opening bracket [.
      • text

        java.lang.String text()
        The text between the first brackets, e.g. `foo` in `[foo][bar]`.
      • label

        java.lang.String label()
        The label, or null for inline links or for shortcut links (in which case text() should be used as the label).
      • destination

        java.lang.String destination()
        The destination if available, e.g. in `[foo](destination)`, or null
      • title

        java.lang.String title()
        The title if available, e.g. in `[foo](destination "title")`, or null
      • afterTextBracket

        Position afterTextBracket()
        The position after the closing text bracket, e.g.:
         [foo][bar]
              ^