QDox
  1. QDox
  2. QDOX-72

JavaClass.getInnerClasses() misleadingly named

    Details

    • Type: Bug Bug
    • Status: Resolved Resolved
    • Priority: Minor Minor
    • Resolution: Fixed
    • Affects Version/s: 1.6
    • Fix Version/s: 1.6
    • Component/s: Java API
    • Labels:
      None
    • Environment:
      N/A
    • Number of attachments :
      0

      Description

      Re.

      http://qdox.codehaus.org/apidocs/com/thoughtworks/qdox/model/JavaClass.html#getInnerClasses()

      The method getInnerClasses() seems to actually be listing all nested classes, including static nested classes, not just inner classes. This is a common misuse of the term "inner class". For definitions see

      http://java.sun.com/docs/books/jls/second_edition/html/classes.doc.html

      and search for "nested" and "inner", specifically

      "An inner class is a nested class that is not explicitly or implicitly declared static."

      You might consider renaming the method to JavaClass.getNestedClasses() for this reason, unless you are really returning only inner classes.

        Activity

        Hide
        Mike Williams added a comment -

        Good point, thanks. We should rename it (and retain getInnerClasses as a deprecated synonym).

        Show
        Mike Williams added a comment - Good point, thanks. We should rename it (and retain getInnerClasses as a deprecated synonym).
        Mike Williams made changes -
        Field Original Value New Value
        Fix Version/s 1.6 [ 10814 ]
        Mike Williams made changes -
        Assignee Mike Williams [ mdub ]
        Hide
        Mike Williams added a comment -

        Fixed for QDox-1.6. getInnerClasses() remains, but is deprecated.

        Show
        Mike Williams added a comment - Fixed for QDox-1.6. getInnerClasses() remains, but is deprecated.
        Mike Williams made changes -
        Resolution Fixed [ 1 ]
        Status Open [ 1 ] Resolved [ 5 ]

          People

          • Assignee:
            Mike Williams
            Reporter:
            Jesse Glick
          • Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Time Tracking

              Estimated:
              Original Estimate - 30 minutes
              30m
              Remaining:
              Remaining Estimate - 30 minutes
              30m
              Logged:
              Time Spent - Not Specified
              Not Specified