Class AnnotationInfo.AnnotationClassRef

  • Enclosing class:
    AnnotationInfo

    public static class AnnotationInfo.AnnotationClassRef
    extends Object
    Stores a class descriptor in an annotation as a class type string, e.g. "[[[java/lang/String;" is stored as "String[][][]".

    Use ReflectionUtils.typeStrToClass() to get a Class<?> reference from this class type string.

    • Method Detail

      • getTypeSignature

        public TypeSignature getTypeSignature()
        Get the type signature for a type reference used in an annotation parameter.

        Call getType() to get a Class<?> reference for this class.

        Returns:
        The type signature of the annotation class ref.
      • getType

        @Deprecated
        public Class<?> getType()
        Deprecated.
        in favor of getClassRef(), for consistency with ClassInfo#getClassRef().
        Get a class reference for a class-reference-typed value used in an annotation parameter. Causes the ClassLoader to load the class.
        Returns:
        The type signature of the annotation class ref, as a Class<?> reference.
      • getClassRef

        public Class<?> getClassRef()
        Get a class reference for a class-reference-typed value used in an annotation parameter. Causes the ClassLoader to load the class.
        Returns:
        The type signature of the annotation class ref, as a Class<?> reference.
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class Object