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

Add an optional description accessor on ToolProvider interface

    XMLWordPrintable

    Details

    • Type: Enhancement
    • Status: Resolved
    • Priority: P4
    • Resolution: Fixed
    • Affects Version/s: 19
    • Fix Version/s: 19
    • Component/s: core-libs
    • Labels:
      None
    • Subcomponent:
    • Resolved In Build:
      b24

      Description

      Add a new default method `description()` on `ToolProvider` that returns a short one-line description of the tool, or an empty `Optional` if no description is available.

      Proposal:

          /**
           * {@return a short description of the tool, or an empty
           * {@code Optional} if no description is available}
           *
           * @apiNote It is recommended that the description fits into a single
           * line in order to allow creating concise overviews like the following:
           * <pre>{@code
           * jar
           * Create, manipulate, and extract an archive of classes and resources.
           * javac
           * Read Java declarations and compile them into class files.
           * jlink
           * Assemble a set of modules (...) into a custom runtime image.
           * }
           * </pre>
           *
           * @since 19
           */
          default Optional<String> description() {
              return Optional.empty();
          }

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              cstein Christian Stein
              Reporter:
              cstein Christian Stein
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved: