public final class AnnotationUtils
extends java.lang.Object
| Modifier and Type | Method and Description |
|---|---|
static <A extends java.lang.annotation.Annotation> |
findAnnotation(java.lang.reflect.AnnotatedElement source,
java.lang.Class<A> targetAnnotationClass)
Deep search of specified annotation considering "annotation as meta annotation" case (annotation annotated with specified annotation).
|
static <A extends java.lang.annotation.Annotation> |
findAnnotation(java.lang.annotation.Annotation source,
java.lang.Class<A> targetAnnotationClass)
Deep search of specified source considering "annotation as meta annotation" case (source annotated with specified source).
|
static <A extends java.lang.annotation.Annotation> |
findTypeAnnotation(java.lang.Class<?> type,
java.lang.Class<A> targetAnnotationClass)
Recursive annotation search on type, it annotations and parents hierarchy.
|
public static <A extends java.lang.annotation.Annotation> A findAnnotation(java.lang.reflect.AnnotatedElement source,
java.lang.Class<A> targetAnnotationClass)
A - the type of the annotation to query for and return if presentsource - specified annotated elementtargetAnnotationClass - specified annotation classpublic static <A extends java.lang.annotation.Annotation> A findAnnotation(java.lang.annotation.Annotation source,
java.lang.Class<A> targetAnnotationClass)
A - type paramsource - Annotation - sourcetargetAnnotationClass - represents class of the required annotaitonA in case if found, null otherwisepublic static <A extends java.lang.annotation.Annotation> A findTypeAnnotation(java.lang.Class<?> type,
java.lang.Class<A> targetAnnotationClass)
A - type paramtype - ClasstargetAnnotationClass - required Annotation classA in case if found, null otherwiseCopyright © 2010-2020 anotheria.net. All Rights Reserved.