java.lang.Object
org.jdrupes.mdoclet.internal.doclets.toolkit.util.DocLink

public class DocLink extends Object
Abstraction for simple relative URIs, consisting of a path and an optional fragment.

DocLink objects can be created by the constructors below or from a DocPath using the convenience fragment method.

  • Konstruktordetails

    • DocLink

      public DocLink(DocPath path)
      Creates a DocLink representing the URI path.
      Parameter:
      path - the path
    • DocLink

      public DocLink(DocPath path, String fragment)
      Creates a DocLink representing the URI path#fragment.

      Any of the component parts may be null.

      Parameter:
      path - the path
      fragment - the fragment
    • DocLink

      public DocLink(String path, String fragment)
      Creates a DocLink representing the URI path#fragment.

      Any of the component parts may be null.

      Parameter:
      path - the path
      fragment - the fragment
  • Methodendetails

    • fragment

      public static DocLink fragment(String fragment)
      Creates a DocLink representing the URI #fragment.
      Parameter:
      fragment - the fragment
      Gibt zurück:
      the DocLink
    • relativizeAgainst

      Creates a DocLink formed by relativizing the path against a given base.
      Parameter:
      base - the base
      Gibt zurück:
      the DocLink
    • withFragment

      public DocLink withFragment(String fragment)
    • toString

      public String toString()
      Returns the link in the form “path#fragment”, omitting any empty components.
      Setzt außer Kraft:
      toString in Klasse Object
      Gibt zurück:
      the string