Improve Annotation.annotationType() documentation

XMLWordPrintable

        A DESCRIPTION OF THE PROBLEM :
        It appears for a java.lang.annotation.Annotation x, one is supposed to call x.annotationType() instead of x.getClass().
        However, currently this is not obvious from the Annotation documentation, neither are the reasons for this explained.

        Expected would be that:
        1. The class documentation of Annotation mentioned that one should prefer annotationType() to getClass()
        2. The annotationType() doc explained why this method should be preferred to calling getClass()


              Assignee:
              Joe Darcy
              Reporter:
              Webbug Group
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

                Created:
                Updated:
                Resolved: