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

Clarify runtime vs compile time annotations for RoundEnvironment.getElementsAnnotatedWith(Class)

    Details

    • Type: Enhancement
    • Status: Resolved
    • Priority: P4
    • Resolution: Fixed
    • Affects Version/s: 12
    • Fix Version/s: 12
    • Component/s: core-libs
    • Labels:

      Description

      The two RoundEnvironment methods:

      RoundEnvironment.getElementsAnnotatedWith​(Class<? extends Annotation> a)
      RoundEnvironment.getElementsAnnotatedWithAny​(Set<Class<? extends
      Annotation>> annotations)

      can expose a difference between annotation types available at runtime via Class objects versus the annotation types available at compile time as TypeElements.

      This hazard should be mentioned in the API docs.

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                darcy Joe Darcy
                Reporter:
                darcy Joe Darcy
              • Votes:
                0 Vote for this issue
                Watchers:
                1 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: