QDox
  1. QDox
  2. QDOX-4

Support inner classes in methods

    Details

    • Type: Improvement Improvement
    • Status: Closed Closed
    • Priority: Trivial Trivial
    • Resolution: Won't Fix
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: Parser
    • Labels:
      None
    • Number of attachments :
      0

      Description

      I haven't written a test case yet, but while incorporating the QDox parser in XJavaDoc, it appeared that the parser ignores inner classes that are defined inside a method.

        Activity

        Hide
        Mike Williams added a comment -

        Yup, the parser ignores everything in the body of a method.

        But I'm confused. Aslak, are you talking about anonymous inner-classes? Can you provide an example of the kind of Javadoc information you'd want to extract?

        Show
        Mike Williams added a comment - Yup, the parser ignores everything in the body of a method. But I'm confused. Aslak, are you talking about anonymous inner-classes? Can you provide an example of the kind of Javadoc information you'd want to extract?
        Hide
        Aslak Hellesøy added a comment -

        No, not anonymous inner classes. Like this:

        /**

        • @foo
          */
          public class A {
          /**
        • @bar
          */
          public void b() {
          /**
        • @zap
          */
          class C {
          public void d() {
          }
          }
          C c = new C();
          c.d();
          }
          }
          }

        I realise this is very ugly, but it's valid Java, and someone (not me!) might want to support it one day.

        It was more for the record than for the need.

        I'll set this one to lowest priority. I don't think it should be fixed until someone reqests it, and then we might reject it since it will probably slow down the parser significantly.

        Show
        Aslak Hellesøy added a comment - No, not anonymous inner classes. Like this: /** @foo */ public class A { /** @bar */ public void b() { /** @zap */ class C { public void d() { } } C c = new C(); c.d(); } } } I realise this is very ugly, but it's valid Java, and someone (not me!) might want to support it one day. It was more for the record than for the need. I'll set this one to lowest priority. I don't think it should be fixed until someone reqests it, and then we might reject it since it will probably slow down the parser significantly.
        Aslak Hellesøy made changes -
        Field Original Value New Value
        Priority Major [ 3 ] Trivial [ 5 ]
        Hide
        Aslak Hellesøy added a comment -

        This is a rare case, and won't be fixed because it would slow down the parser. Method-inner classes are never needed, they can be replaced by regular inner classes.

        Show
        Aslak Hellesøy added a comment - This is a rare case, and won't be fixed because it would slow down the parser. Method-inner classes are never needed, they can be replaced by regular inner classes.
        Aslak Hellesøy made changes -
        Resolution Won't Fix [ 2 ]
        Status Assigned [ 2 ] Closed [ 6 ]

          People

          • Assignee:
            Joe Walnes
            Reporter:
            Aslak Hellesøy
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: