public final class AnnotationManager extends Object
Constructor and Description |
---|
AnnotationManager(WebBeansContext context) |
Modifier and Type | Method and Description |
---|---|
void |
checkDecoratorResolverParams(Set<Type> apiTypes,
Annotation... qualifiers) |
Annotation[] |
checkForNewQualifierForDeployment(Type type,
Class<?> clazz,
String name,
Annotation[] annotations)
Check conditions for the new binding.
|
void |
checkInjectionPointForInjectInjectionPoint(Class<?> clazz)
JavaEE components can not inject
InjectionPoint . |
void |
checkInterceptorResolverParams(Annotation... interceptorBindings) |
void |
checkQualifierConditions(Annotation... qualifierAnnots) |
void |
checkQualifierConditions(Set<Annotation> qualifierAnnots)
This function obviously cannot check for duplicate annotations.
|
void |
checkStereoTypeClass(Class<? extends Annotation> clazz,
Annotation... annotations)
Validates that given class obeys stereotype model
defined by the specification.
|
<X> Annotation[] |
getAnnotatedMethodFirstParameterQualifierWithGivenAnnotation(javax.enterprise.inject.spi.AnnotatedMethod<X> annotatedMethod,
Class<? extends Annotation> clazz) |
Annotation |
getDeclaredScopeAnnotation(Class<?> beanClass) |
<X> Method |
getDisposalWithGivenAnnotatedMethod(javax.enterprise.inject.spi.AnnotatedType<X> annotatedType,
Type beanType,
Annotation[] qualifiers) |
Set<Annotation> |
getInterceptorAnnotations(Set<Annotation> typeAnns)
This method searches for all direct and indirect annotations which
represent an
InterceptorBinding . |
Annotation[] |
getInterceptorBindingMetaAnnotations(Annotation[] anns)
Collect the interceptor bindings from an array of annotations, including
transitively defined interceptor bindings.
|
Annotation[] |
getInterceptorBindingMetaAnnotations(Set<Annotation> anns)
Collect the interceptor bindings from an array of annotations, including
transitively defined interceptor bindings.
|
Annotation[] |
getMethodFirstParameterQualifierWithGivenAnnotation(Method method,
Class<? extends Annotation> clazz)
Gets the method first found parameter qualifiers.
|
Annotation[] |
getQualifierAnnotations(Annotation... annotations)
Gets the array of qualifier annotations on the given array.
|
Set<Annotation> |
getQualifierAnnotations(Set<Annotation> annotations) |
Annotation[] |
getStereotypeMetaAnnotations(Annotation[] anns) |
Set<Class<? extends Annotation>> |
getStereotypeMetaAnnotations(Set<Class<? extends Annotation>> stereotypes)
Same like
getStereotypeMetaAnnotations(java.util.Set) but with an array |
Set<Class<? extends Annotation>> |
getStereotypes(Set<Class<? extends Annotation>> anns)
Returns bean stereotypes.
|
boolean |
hasInterceptorBindingMetaAnnotation(Annotation[] anns)
If any Annotations in the input is an interceptor binding annotation type then return
true, false otherwise.
|
boolean |
hasNamedOnStereoTypes(Set<Class<? extends Annotation>> stereotypes)
Returns true if name exists,false otherwise.
|
boolean |
hasStereoTypeMetaAnnotation(Annotation[] anns) |
boolean |
hasStereoTypeMetaAnnotation(Set<Class<? extends Annotation>> anns) |
boolean |
isInterceptorBindingAnnotation(Class<? extends Annotation> clazz)
Returns true if the annotation is defined in xml or annotated with
InterceptorBinding or an InterceptorBinding
registered via BeforeBeanDiscovery . |
boolean |
isQualifierAnnotation(Class<? extends Annotation> clazz)
Returns true if the annotation is defined in xml or annotated with
Qualifier false otherwise. |
boolean |
isStereoTypeAnnotation(Class<? extends Annotation> clazz)
Returns true if the annotation is defined in xml or annotated with
Stereotype false otherwise. |
boolean |
isSuperMethodNamed(AbstractOwbBean<?> component,
Method method,
Method superMethod)
Configures the name of the producer method for specializing the parent.
|
public AnnotationManager(WebBeansContext context)
public Annotation getDeclaredScopeAnnotation(Class<?> beanClass)
public boolean isInterceptorBindingAnnotation(Class<? extends Annotation> clazz)
InterceptorBinding
or an InterceptorBinding
registered via BeforeBeanDiscovery
.
False otherwise.clazz
- type of the annotationInterceptorBinding
, false otherwisepublic Set<Annotation> getInterceptorAnnotations(Set<Annotation> typeAnns)
InterceptorBinding
.
InterceptorBindings in stereotypes will also be found!public boolean hasInterceptorBindingMetaAnnotation(Annotation[] anns)
anns
- array of Annotations to checkpublic Annotation[] getInterceptorBindingMetaAnnotations(Set<Annotation> anns)
anns
- An array of annotationspublic Annotation[] getInterceptorBindingMetaAnnotations(Annotation[] anns)
anns
- An array of annotationspublic boolean isQualifierAnnotation(Class<? extends Annotation> clazz)
Qualifier
false otherwise.clazz
- type of the annotationQualifier
false otherwisepublic <X> Annotation[] getAnnotatedMethodFirstParameterQualifierWithGivenAnnotation(javax.enterprise.inject.spi.AnnotatedMethod<X> annotatedMethod, Class<? extends Annotation> clazz)
public Annotation[] getMethodFirstParameterQualifierWithGivenAnnotation(Method method, Class<? extends Annotation> clazz)
method
- methodclazz
- checking annotationpublic Set<Annotation> getQualifierAnnotations(Set<Annotation> annotations)
public Annotation[] getQualifierAnnotations(Annotation... annotations)
annotations
- annotation arraypublic void checkQualifierConditions(Annotation... qualifierAnnots)
public void checkQualifierConditions(Set<Annotation> qualifierAnnots)
qualifierAnnots
- public boolean isStereoTypeAnnotation(Class<? extends Annotation> clazz)
Stereotype
false otherwise.clazz
- type of the annotationStereotype
false otherwisepublic boolean hasStereoTypeMetaAnnotation(Set<Class<? extends Annotation>> anns)
public boolean hasStereoTypeMetaAnnotation(Annotation[] anns)
public Annotation[] getStereotypeMetaAnnotations(Annotation[] anns)
public Set<Class<? extends Annotation>> getStereotypeMetaAnnotations(Set<Class<? extends Annotation>> stereotypes)
getStereotypeMetaAnnotations(java.util.Set)
but with an arraypublic Set<Class<? extends Annotation>> getStereotypes(Set<Class<? extends Annotation>> anns)
public boolean hasNamedOnStereoTypes(Set<Class<? extends Annotation>> stereotypes)
public void checkStereoTypeClass(Class<? extends Annotation> clazz, Annotation... annotations)
clazz
- stereotype classpublic void checkInterceptorResolverParams(Annotation... interceptorBindings)
public void checkDecoratorResolverParams(Set<Type> apiTypes, Annotation... qualifiers)
public Annotation[] checkForNewQualifierForDeployment(Type type, Class<?> clazz, String name, Annotation[] annotations)
annotations
- annotationsWebBeansConfigurationException
- if New plus any other binding annotation is setpublic boolean isSuperMethodNamed(AbstractOwbBean<?> component, Method method, Method superMethod)
component
- producer method componentmethod
- specialized producer methodsuperMethod
- overriden super producer methodpublic <X> Method getDisposalWithGivenAnnotatedMethod(javax.enterprise.inject.spi.AnnotatedType<X> annotatedType, Type beanType, Annotation[] qualifiers)
public void checkInjectionPointForInjectInjectionPoint(Class<?> clazz)
InjectionPoint
.clazz
- javaee component class infoWebBeansConfigurationException
- exception if condition is not appliedCopyright © 2008–2016 The Apache Software Foundation. All rights reserved.