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

Improve JVMCI annotation handling

XMLWordPrintable

      The current design of jdk.vm.ci.meta.AnnotationData and jdk.vm.ci.meta.Annotated can be improved to have better naming and to support more use cases.

      In terms of improving naming:

      * AnnotationData -> AnnotationValue (avoids confusion with java.lang.Class.AnnotationData)
      * The 2 versions of Annotated#getAnnotationData should be renamed to getAnnotationValue (for retrieving a single annotation value) and getAnnotationValues (for retrieving multiple annotation values).

      The getAnnotationValues method above will have a single varargs value which, when it has a length of 0 will return all annotations declared on an element.

            dnsimon Douglas Simon
            dnsimon Douglas Simon
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated: