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

Undocumented types leak to javadoc output

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: P4 P4
    • tbd
    • 21
    • tools
    • None

      JavaDoc has to deal with "non-public intermediate types" or "non-public superclasses or superinterfaces".

      Filtering out such classes or interfaces (hereafter referred to as "types" for simplicity) produces unexplained features in the inheritance hierarchy. For example, consider StringBuilder. The page for that type reports the following:


      Class StringBuilder

      java.lang.Object
        java.lang.StringBuilder

      All Implemented Interfaces:
      Serializable, Appendable, CharSequence, Comparable<StringBuilder>


      Now, if you look at the pages for Object, Serializable, CharSequence, and Comparable, you'll see that neither of those types has Appendable as its supertype.

      Where does Appendable come from? It comes from the undocumented direct supertype of StringBuilder, java.lang.AbstractStringBuilder.

      We should investigate if it is possible to deal with non-public types in such a way that they don't leak into the documentation. It might turn out to be impossible to preserve a complete illusion that those types do not exist.

            Unassigned Unassigned
            prappo Pavel Rappo (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated: