Interface EnhancedAnnotated<T,S>
- All Superinterfaces:
jakarta.enterprise.inject.spi.Annotated
- All Known Subinterfaces:
EnhancedAnnotatedCallable<T,,X, S> EnhancedAnnotatedConstructor<T>,EnhancedAnnotatedField<T,,X> EnhancedAnnotatedMember<T,,X, S> EnhancedAnnotatedMethod<T,,X> EnhancedAnnotatedParameter<T,,X> EnhancedAnnotatedType<T>,EnhancedAnnotation<T>
- All Known Implementing Classes:
AbstractEnhancedAnnotated,AbstractEnhancedAnnotatedCallable,AbstractEnhancedAnnotatedMember,EnhancedAnnotatedConstructorImpl,EnhancedAnnotatedFieldImpl,EnhancedAnnotatedMethodImpl,EnhancedAnnotatedParameterImpl,EnhancedAnnotatedTypeImpl,EnhancedAnnotationImpl
public interface EnhancedAnnotated<T,S>
extends jakarta.enterprise.inject.spi.Annotated
AnnotatedItem provides uniform access to the annotations on an annotated item defined either in Java or XML
- Author:
- Pete Muir
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final Set<Class<? extends Annotation>>The set of declared meta-annotations to mapstatic final Set<Class<? extends Annotation>>The set of meta-annotations to map -
Method Summary
Modifier and TypeMethodDescriptionType[]Gets the actual type arguments for any parameterized types that this AnnotatedItem represents.default Annotation[]Gets the binding types for this elementGet the type hierarchy of any interfaces implemented by this class.Gets the type of the elementgetMetaAnnotations(Class<? extends Annotation> metaAnnotationType) Gets all annotations which are annotated with the given meta annotation typegetName()Gets the name of this AnnotatedItemGets the binding types for this elementbooleanisFinal()Indicates if this AnnotatedItem represents a final elementbooleanbooleanbooleanbooleanbooleanbooleanisPublic()Indicates if this annotated item is publicbooleanisStatic()Indicates if this AnnotatedItem represents a static elementjakarta.enterprise.inject.spi.Annotatedslim()Returns a lightweight implementation ofAnnotatedwith minimal memory footprint.Methods inherited from interface jakarta.enterprise.inject.spi.Annotated
getAnnotation, getAnnotations, getAnnotations, getBaseType, getTypeClosure, isAnnotationPresent
-
Field Details
-
MAPPED_METAANNOTATIONS
The set of meta-annotations to map -
MAPPED_DECLARED_METAANNOTATIONS
The set of declared meta-annotations to map
-
-
Method Details
-
getMetaAnnotations
Gets all annotations which are annotated with the given meta annotation type- Parameters:
The- meta annotation to match- Returns:
- A set of matching meta-annotations. Returns an empty set if there are no matches.
-
getQualifiers
Set<Annotation> getQualifiers()Gets the binding types for this elementThis reflection type should not know about CDI qualifiers. However, it is very convenient, so we keep it here.
-
getBindingsAsArray
Gets the binding types for this elementThis reflection type should not know about CDI qualifiers. However, it is very convenient, so we keep it here.
-
getInterfaceClosure
Get the type hierarchy of any interfaces implemented by this class. The returned types should have any type parameters resolved to their actual types. There is no guarantee this methods executes in O(1) time- Returns:
- the type hierarchy
-
getJavaClass
Gets the type of the element- Returns:
- The type of the element
-
getActualTypeArguments
Type[] getActualTypeArguments()Gets the actual type arguments for any parameterized types that this AnnotatedItem represents.- Returns:
- An array of type arguments
-
isStatic
boolean isStatic()Indicates if this AnnotatedItem represents a static element- Returns:
- True if static, false otherwise
-
isGeneric
boolean isGeneric() -
isFinal
boolean isFinal()Indicates if this AnnotatedItem represents a final element- Returns:
- True if final, false otherwise
-
isPublic
boolean isPublic()Indicates if this annotated item is public- Returns:
- if public, returns true
-
isPrivate
boolean isPrivate() -
isPackagePrivate
boolean isPackagePrivate() -
getPackage
Package getPackage() -
getName
String getName()Gets the name of this AnnotatedItem If it is not possible to determine the name of the underling element, a IllegalArgumentException is thrown- Returns:
- The name
-
isParameterizedType
boolean isParameterizedType() -
isPrimitive
boolean isPrimitive() -
slim
jakarta.enterprise.inject.spi.Annotated slim()Returns a lightweight implementation ofAnnotatedwith minimal memory footprint.- Returns:
- the slim version of this
Annotated
-