Home » apache-openwebbeans-1.0.0-incubating-M3-sources » org.apache.webbeans.util » [javadoc | source]
org.apache.webbeans.util
public final class: AnnotationUtil [javadoc | source]
java.lang.Object
   org.apache.webbeans.util.AnnotationUtil
Utility class related with Annotation operations.
Method from org.apache.webbeans.util.AnnotationUtil Summary:
checkQualifierConditions,   getAnnotation,   getAnnotationsFromSet,   getClazzFieldsWithGivenAnnotation,   getConstructorParameterGenericTypesWithGivenAnnotation,   getInterceptorBindingMetaAnnotations,   getMetaAnnotations,   getMethodFirstParameterAnnotation,   getMethodFirstParameterQualifierWithGivenAnnotation,   getMethodFirstParameterTypeClazzWithAnnotation,   getMethodFirstParameterWithAnnotation,   getMethodParameterGenericTypesWithGivenAnnotation,   getMethodsWithAnnotation,   getMethodsWithParameterAnnotation,   getQualifierAnnotations,   getRealizesGenericAnnotations,   getResourceAnnotations,   getStereotypeMetaAnnotations,   hasResourceAnnotation,   isAnnotationExist,   isAnnotationExistOnClass,   isAnnotationMemberExist,   isAnyQualifierExist,   isInterceptorBindingAnnotation,   isInterceptorBindingMetaAnnotationExist,   isMetaAnnotationExist,   isMethodHasAnnotation,   isMethodHasResourceAnnotation,   isMethodMultipleParameterAnnotationExist,   isMethodParameterAnnotationCrossRefExist,   isMethodParameterAnnotationExist,   isQualifierAnnotation,   isResourceAnnotation,   isStereoTypeAnnotation,   isStereoTypeMetaAnnotationExist
Methods from java.lang.Object:
clone,   equals,   finalize,   getClass,   hashCode,   notify,   notifyAll,   toString,   wait,   wait,   wait
Method from org.apache.webbeans.util.AnnotationUtil Detail:
 public static  void checkQualifierConditions(Annotation qualifierAnnots) 
 public static Annotation getAnnotation(Annotation[] anns,
    Class<Annotation> annotation) 
    get the annotation of the given type from the array.
 public static Annotation[] getAnnotationsFromSet(Set<Annotation> set) 
 public static Field[] getClazzFieldsWithGivenAnnotation(Class<?> clazz,
    Class<Annotation> annotation) 
 public static Type[] getConstructorParameterGenericTypesWithGivenAnnotation(Constructor<?> constructor,
    Class<Annotation> clazz) 
 public static Annotation[] getInterceptorBindingMetaAnnotations(Annotation[] anns) 
 public static Annotation[] getMetaAnnotations(Annotation[] anns,
    Class<Annotation> metaAnnotation) 
 public static T getMethodFirstParameterAnnotation(Method method,
    Class<T> clazz) 
    Gets the method first found parameter annotation with given type.
 public static Annotation[] getMethodFirstParameterQualifierWithGivenAnnotation(Method method,
    Class<Annotation> clazz) 
    Gets the method first found parameter qualifiers.
 public static Class<?> getMethodFirstParameterTypeClazzWithAnnotation(Method method,
    Class<Annotation> clazz) 
 public static Type getMethodFirstParameterWithAnnotation(Method method,
    Class<Annotation> clazz) 
    Gets the method first found parameter type that is annotated with the given annotation.
 public static Type[] getMethodParameterGenericTypesWithGivenAnnotation(Method method,
    Class<Annotation> clazz) 
 public static Method[] getMethodsWithAnnotation(Class<?> clazz,
    Class<Annotation> annotation) 
    Gets array of methods that has given annotation type.
 public static Method[] getMethodsWithParameterAnnotation(Class<?> clazz,
    Class<Annotation> annotation) 
    Gets array of methods that has parameter with given annotation type.
 public static Annotation[] getQualifierAnnotations(Annotation annotations) 
    Gets the array of qualifier annotations on the given array.
 public static Annotation[] getRealizesGenericAnnotations(Class<?> clazz,
    Annotation[] anns) 
    If the bean extends generic class via Realizes annotation, realized based producer methods, fields and observer methods qualifier is
    • Qualifiers on the definitions
    • Plus class qualifiers
    • Minus generic class qualifiers
 public static Annotation[] getResourceAnnotations(Annotation annotations) 
    Gets the array of resource annotations on the given array.
 public static Annotation[] getStereotypeMetaAnnotations(Annotation[] anns) 
 public static boolean hasResourceAnnotation(Annotation[] annotations) 
    check if any of the given resources is a resource annotation
 public static boolean isAnnotationExist(Annotation[] anns,
    Class<Annotation> annotation) 
 public static boolean isAnnotationExistOnClass(Class<?> clazz,
    Class<Annotation> annotation) 
    Check whether or not class contains the given annotation.
 public static boolean isAnnotationMemberExist(Class<Annotation> clazz,
    Annotation src,
    Annotation member) 
    Returns true if the injection point binding type and NonBinding member values are equal to the given member annotation.
 public static boolean isAnyQualifierExist(Bean<?> bean) 
    Returns true if any binding exist
 public static boolean isInterceptorBindingAnnotation(Class<Annotation> clazz) 
 public static boolean isInterceptorBindingMetaAnnotationExist(Annotation[] anns) 
    If candidate class has an interceptor binding annotation type then return true, false otherwise.
 public static boolean isMetaAnnotationExist(Annotation[] anns,
    Class<Annotation> metaAnnotation) 
 public static boolean isMethodHasAnnotation(Method method,
    Class<Annotation> clazz) 
    Check given annotation exist on the method.
 public static boolean isMethodHasResourceAnnotation(Method method) 
    Check if a resource annotation exist on the method.
 public static boolean isMethodMultipleParameterAnnotationExist(Method method,
    Class<Annotation> clazz) 
    Check given annotation exist in the multiple parameter of the given method. Return true if exist false otherwise.
 public static boolean isMethodParameterAnnotationCrossRefExist(Method method,
    Class<Annotation> clazz) 
    Check given annotation cross ref exist in the any parameter of the given method. Return true if exist false otherwise.
 public static boolean isMethodParameterAnnotationExist(Method method,
    Class<Annotation> clazz) 
    Check given annotation exist in the any parameter of the given method. Return true if exist false otherwise.
 public static boolean isQualifierAnnotation(Class<Annotation> clazz) 
 public static boolean isResourceAnnotation(Class<Annotation> clazz) 
    Returns true if the annotation is a valid WebBeans Resource, a resource defined in common annotations JSR-250, a remote EJB or a web service. The following annotations indicate resources
    1. @CustomerDataservice
    2. @Resource
    3. @PersistenceContext
    4. @PersistenceUnit
    5. @EJB
    6. @WebServiceRef
    7. @
    Please note that @PersistenceContext(type=EXTENDED) is not supported for simple beans.
 public static boolean isStereoTypeAnnotation(Class<Annotation> clazz) 
    Returns true if the annotation is defined in xml or annotated with Stereotype false otherwise.
 public static boolean isStereoTypeMetaAnnotationExist(Annotation[] anns)