Class AnnotationWrapper

  • All Implemented Interfaces:
    java.lang.reflect.InvocationHandler, javax.lang.model.element.AnnotationMirror, Writable

    public class AnnotationWrapper
    extends java.lang.Object
    implements javax.lang.model.element.AnnotationMirror, Writable, java.lang.reflect.InvocationHandler
    • Method Summary

      All Methods Instance Methods Concrete Methods Deprecated Methods 
      Modifier and Type Method Description
      <A extends java.lang.annotation.Annotation>
      A
      getAnnotation​(java.lang.Class<A> annotationType)  
      javax.lang.model.type.DeclaredType getAnnotationType()  
      (package private) java.lang.String getDescriptor()  
      ElementValue getElement​(java.lang.String name)
      Deprecated. 
      java.util.Map<? extends javax.lang.model.element.ExecutableElement,​? extends javax.lang.model.element.AnnotationValue> getElementValues()  
      java.util.Map<? extends javax.lang.model.element.ExecutableElement,​? extends javax.lang.model.element.AnnotationValue> getElementValuesWithDefaults()  
      private javax.lang.model.element.ExecutableElement getExecutableElement​(java.lang.String name)  
      int getLength()  
      java.lang.Object invoke​(java.lang.Object proxy, java.lang.reflect.Method method, java.lang.Object[] args)  
      java.lang.String toString()  
      void write​(java.io.DataOutput out)  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
    • Field Detail

      • typeIndex

        private int typeIndex
      • annotationType

        private javax.lang.model.type.DeclaredType annotationType
      • elementValues

        private java.util.Map<javax.lang.model.element.ExecutableElement,​javax.lang.model.element.AnnotationValue> elementValues
      • elementValuesWithDefaults

        private java.util.Map<javax.lang.model.element.ExecutableElement,​javax.lang.model.element.AnnotationValue> elementValuesWithDefaults
      • typeElement

        private final javax.lang.model.element.TypeElement typeElement
    • Constructor Detail

      • AnnotationWrapper

        public AnnotationWrapper​(ClassFile classFile,
                                 java.io.DataInput in)
                          throws java.io.IOException
        Throws:
        java.io.IOException
    • Method Detail

      • getExecutableElement

        private javax.lang.model.element.ExecutableElement getExecutableElement​(java.lang.String name)
      • getAnnotationType

        public javax.lang.model.type.DeclaredType getAnnotationType()
        Specified by:
        getAnnotationType in interface javax.lang.model.element.AnnotationMirror
      • getElementValues

        public java.util.Map<? extends javax.lang.model.element.ExecutableElement,​? extends javax.lang.model.element.AnnotationValue> getElementValues()
        Specified by:
        getElementValues in interface javax.lang.model.element.AnnotationMirror
      • getElementValuesWithDefaults

        public java.util.Map<? extends javax.lang.model.element.ExecutableElement,​? extends javax.lang.model.element.AnnotationValue> getElementValuesWithDefaults()
      • getAnnotation

        public <A extends java.lang.annotation.Annotation> A getAnnotation​(java.lang.Class<A> annotationType)
      • getDescriptor

        java.lang.String getDescriptor()
      • getElement

        public ElementValue getElement​(java.lang.String name)
        Deprecated.
        Parameters:
        name -
        Returns:
      • getLength

        public int getLength()
      • write

        public void write​(java.io.DataOutput out)
                   throws java.io.IOException
        Specified by:
        write in interface Writable
        Throws:
        java.io.IOException
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object
      • invoke

        public java.lang.Object invoke​(java.lang.Object proxy,
                                       java.lang.reflect.Method method,
                                       java.lang.Object[] args)
                                throws java.lang.Throwable
        Specified by:
        invoke in interface java.lang.reflect.InvocationHandler
        Throws:
        java.lang.Throwable