Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8219959

Automatically load taglets from a jar file

    Details

    • Type: CSR
    • Status: Closed
    • Priority: P3
    • Resolution: Approved
    • Fix Version/s: 13
    • Component/s: tools
    • Labels:
      None
    • Subcomponent:
    • Compatibility Kind:
      behavioral
    • Compatibility Risk:
      low
    • Compatibility Risk Description:
      This is a new feature being added; it is highly unlikely that there is any existing conflicting usage of such configuration files.
    • Interface Kind:
      add/remove/modify command line option, File or wire format

      Description

      Summary

      Provide the ability to automatically load taglets from a jar file.

      Problem

      Users have asked to be able to put multiple taglets in a single jar file and to have the javadoc tool load them automatically, rather than having to call out each taglet separately using the -taglet command-line option.

      Solution

      Support the use of a standard service-provider configuration file in jar files found on the taglet path.

      Within the javadoc tool, the TagletManager class will use java.util.ServiceLoader class to automatically load all the taglet classes specified in the configuration file.

      Specification

      This behavior will be enabled when a jar file containing a suitable service-provider configuration file is found on the taglet path.

      • The file must be named jdk.javadoc.doclet.Taglet and placed in the META-INF/services directory in the jar file.

      • The file must contain the fully qualified name of each of the taglet implementation classes that are to be loaded automatically.

      The taglet manager will load all the taglets specified in the serice-provider configuration file. There is no need to used the -taglet option for individual taglets specified in that file.

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                pmuthuswamy Priya Lakshmi Muthuswamy (Inactive)
                Reporter:
                pmuthuswamy Priya Lakshmi Muthuswamy (Inactive)
                Reviewed By:
                Jonathan Gibbons
              • Votes:
                0 Vote for this issue
                Watchers:
                2 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: