@ParametersAreNonnullByDefault
public class AnnotationUtils
extends java.lang.Object
| Constructor and Description |
|---|
AnnotationUtils() |
| Modifier and Type | Method and Description |
|---|---|
static java.util.Optional<org.objectweb.asm.tree.AnnotationNode> |
findAnnotation(java.util.List<org.objectweb.asm.tree.AnnotationNode> annotations,
java.lang.Class<?> annotationClass)
Find an annotation in a list of annotations.
|
static java.util.Optional<org.objectweb.asm.tree.AnnotationNode> |
findAnnotation(java.util.List<org.objectweb.asm.tree.AnnotationNode> annotations,
java.lang.String annotationDescriptor)
Find an annotation in a list of annotations.
|
static java.util.Optional<org.objectweb.asm.tree.AnnotationNode> |
findInvisibleAnnotation(org.objectweb.asm.tree.ClassNode classNode,
java.lang.Class<?> annotationClass)
Find an invisible annotation in a
ClassNode. |
static java.util.Optional<org.objectweb.asm.tree.AnnotationNode> |
findInvisibleAnnotation(org.objectweb.asm.tree.ClassNode classNode,
java.lang.String annotationDescriptor)
Find an invisible annotation in a
ClassNode. |
static java.util.Optional<org.objectweb.asm.tree.AnnotationNode> |
findInvisibleAnnotation(org.objectweb.asm.tree.MethodNode methodNode,
java.lang.Class<?> annotationClass)
Find an invisible annotation in a
MethodNode. |
static java.util.Optional<org.objectweb.asm.tree.AnnotationNode> |
findInvisibleAnnotation(org.objectweb.asm.tree.MethodNode methodNode,
java.lang.String annotationDescriptor)
Find an invisible annotation in a
MethodNode. |
static boolean |
hasAnnotation(java.util.List<org.objectweb.asm.tree.AnnotationNode> annotations,
java.lang.Class<?> annotationClass)
Check if a list of annotations has an annotation.
|
static boolean |
hasAnnotation(java.util.List<org.objectweb.asm.tree.AnnotationNode> annotations,
java.lang.String annotationDescriptor)
Check if a list of annotations has an annotation.
|
static boolean |
hasInvisibleAnnotation(org.objectweb.asm.tree.ClassNode classNode,
java.lang.Class<?> annotationClass)
Check if a
ClassNode has an invisible annotation. |
static boolean |
hasInvisibleAnnotation(org.objectweb.asm.tree.ClassNode classNode,
java.lang.String annotationDescriptor)
Check if a
ClassNode has an invisible annotation. |
static boolean |
hasInvisibleAnnotation(org.objectweb.asm.tree.MethodNode methodNode,
java.lang.Class<?> annotationClass)
Check if a
MethodNode has an invisible annotation. |
static boolean |
hasInvisibleAnnotation(org.objectweb.asm.tree.MethodNode methodNode,
java.lang.String annotationDescriptor)
Check if a
MethodNode has an invisible annotation. |
public static java.util.Optional<org.objectweb.asm.tree.AnnotationNode> findInvisibleAnnotation(org.objectweb.asm.tree.ClassNode classNode,
java.lang.Class<?> annotationClass)
ClassNode.classNode - The class node to search inannotationClass - The annotation class to search forpublic static java.util.Optional<org.objectweb.asm.tree.AnnotationNode> findInvisibleAnnotation(org.objectweb.asm.tree.ClassNode classNode,
java.lang.String annotationDescriptor)
ClassNode.classNode - The class node to search inannotationDescriptor - The descriptor of the annotation to search forpublic static java.util.Optional<org.objectweb.asm.tree.AnnotationNode> findInvisibleAnnotation(org.objectweb.asm.tree.MethodNode methodNode,
java.lang.Class<?> annotationClass)
MethodNode.methodNode - The method node to search inannotationClass - The annotation class to search forpublic static java.util.Optional<org.objectweb.asm.tree.AnnotationNode> findInvisibleAnnotation(org.objectweb.asm.tree.MethodNode methodNode,
java.lang.String annotationDescriptor)
MethodNode.methodNode - The method node to search inannotationDescriptor - The descriptor of the annotation to search forpublic static java.util.Optional<org.objectweb.asm.tree.AnnotationNode> findAnnotation(@Nullable
java.util.List<org.objectweb.asm.tree.AnnotationNode> annotations,
java.lang.Class<?> annotationClass)
annotations - The list of annotations to search inannotationClass - The annotation class to search forpublic static java.util.Optional<org.objectweb.asm.tree.AnnotationNode> findAnnotation(@Nullable
java.util.List<org.objectweb.asm.tree.AnnotationNode> annotations,
java.lang.String annotationDescriptor)
annotations - The list of annotations to search inannotationDescriptor - The descriptor of the annotation to search forpublic static boolean hasInvisibleAnnotation(org.objectweb.asm.tree.ClassNode classNode,
java.lang.Class<?> annotationClass)
ClassNode has an invisible annotation.classNode - The class node to search inannotationClass - The annotation class to search forpublic static boolean hasInvisibleAnnotation(org.objectweb.asm.tree.ClassNode classNode,
java.lang.String annotationDescriptor)
ClassNode has an invisible annotation.classNode - The class node to search inannotationDescriptor - The descriptor of the annotation to search forpublic static boolean hasInvisibleAnnotation(org.objectweb.asm.tree.MethodNode methodNode,
java.lang.Class<?> annotationClass)
MethodNode has an invisible annotation.methodNode - The method node to search inannotationClass - The annotation class to search forpublic static boolean hasInvisibleAnnotation(org.objectweb.asm.tree.MethodNode methodNode,
java.lang.String annotationDescriptor)
MethodNode has an invisible annotation.methodNode - The method node to search inannotationDescriptor - The descriptor of the annotation to search forpublic static boolean hasAnnotation(@Nullable
java.util.List<org.objectweb.asm.tree.AnnotationNode> annotations,
java.lang.Class<?> annotationClass)
annotations - The list of annotations to search inannotationClass - The annotation class to search forpublic static boolean hasAnnotation(@Nullable
java.util.List<org.objectweb.asm.tree.AnnotationNode> annotations,
java.lang.String annotationDescriptor)
annotations - The list of annotations to search inannotationDescriptor - The descriptor of the annotation to search for