public interface AnnotationMetadata extends AnnotationSource
An interface implemented at compile time by Micronaut that allows the inspection of annotation metadata and stereotypes (meta-annotations)
.
This interface exposes fast and efficient means to expose annotation data at runtime without requiring reflective tricks to read the annotation metadata
Users of Micronaut should in general avoid the methods of the AnnotatedElement
interface and use this interface instead to obtain maximum efficiency
Core framework types such as io.micronaut.inject.BeanDefinition and io.micronaut.inject.ExecutableMethod implement this interface
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
CLASS_NAME_SUFFIX
The suffix used when saving compiled metadata to classes.
|
static AnnotationMetadata |
EMPTY_METADATA
A constant for representing empty metadata.
|
static java.lang.String |
VALUE_MEMBER
The default value() member.
|
EMPTY
Modifier and Type | Method and Description |
---|---|
default java.util.Optional<java.lang.Boolean> |
booleanValue(java.lang.Class<? extends java.lang.annotation.Annotation> annotation)
The value as an optional boolean for the given annotation and member.
|
default java.util.Optional<java.lang.Boolean> |
booleanValue(java.lang.Class<? extends java.lang.annotation.Annotation> annotation,
java.lang.String member)
The value as an optional boolean for the given annotation and member.
|
default java.util.Optional<java.lang.Boolean> |
booleanValue(java.lang.String annotation)
The value as an optional boolean for the given annotation and member.
|
default java.util.Optional<java.lang.Boolean> |
booleanValue(java.lang.String annotation,
java.lang.String member)
The value as an optional boolean for the given annotation and member.
|
default java.util.Optional<java.lang.Class> |
classValue(java.lang.Class<? extends java.lang.annotation.Annotation> annotation)
The value of the annotation as a Class.
|
default java.util.Optional<java.lang.Class> |
classValue(java.lang.Class<? extends java.lang.annotation.Annotation> annotation,
java.lang.String member)
The value of the annotation as a Class.
|
default java.util.Optional<java.lang.Class> |
classValue(java.lang.String annotation)
The value of the annotation as a Class.
|
default java.util.Optional<java.lang.Class> |
classValue(java.lang.String annotation,
java.lang.String member)
The value of the annotation as a Class.
|
default <T> java.lang.Class<T>[] |
classValues(java.lang.Class<? extends java.lang.annotation.Annotation> annotation)
The value of the annotation as a Class.
|
default <T> java.lang.Class<T>[] |
classValues(java.lang.Class<? extends java.lang.annotation.Annotation> annotation,
java.lang.String member)
The value of the annotation as a Class.
|
default <T> java.lang.Class<T>[] |
classValues(java.lang.String annotation)
The value of the annotation as a Class.
|
default <T> java.lang.Class<T>[] |
classValues(java.lang.String annotation,
java.lang.String member)
The value of the annotation as a Class.
|
default java.util.OptionalDouble |
doubleValue(java.lang.Class<? extends java.lang.annotation.Annotation> annotation)
The value as an
OptionalDouble for the given annotation and member. |
default java.util.OptionalDouble |
doubleValue(java.lang.Class<? extends java.lang.annotation.Annotation> annotation,
java.lang.String member)
The value as an
OptionalDouble for the given annotation and member. |
default java.util.OptionalDouble |
doubleValue(java.lang.String annotation,
java.lang.String member)
The value as an
OptionalDouble for the given annotation and member. |
default <E extends java.lang.Enum> |
enumValue(java.lang.Class<? extends java.lang.annotation.Annotation> annotation,
java.lang.Class<E> enumType)
The value of the annotation as a Class.
|
default <E extends java.lang.Enum> |
enumValue(java.lang.Class<? extends java.lang.annotation.Annotation> annotation,
java.lang.String member,
java.lang.Class<E> enumType)
The value of the annotation as a Class.
|
default <E extends java.lang.Enum> |
enumValue(java.lang.String annotation,
java.lang.Class<E> enumType)
The value of the given enum.
|
default <E extends java.lang.Enum> |
enumValue(java.lang.String annotation,
java.lang.String member,
java.lang.Class<E> enumType)
The value of the annotation as a Class.
|
default <E extends java.lang.Enum> |
enumValues(java.lang.Class<? extends java.lang.annotation.Annotation> annotation,
java.lang.Class<E> enumType)
The enum values for the given annotation.
|
default <E extends java.lang.Enum> |
enumValues(java.lang.Class<? extends java.lang.annotation.Annotation> annotation,
java.lang.String member,
java.lang.Class<E> enumType)
The enum values for the given annotation.
|
default <E extends java.lang.Enum> |
enumValues(java.lang.String annotation,
java.lang.Class<E> enumType)
The enum values for the given annotation.
|
default <E extends java.lang.Enum> |
enumValues(java.lang.String annotation,
java.lang.String member,
java.lang.Class<E> enumType)
The enum values for the given annotation.
|
default <T extends java.lang.annotation.Annotation> |
findAnnotation(java.lang.Class<T> annotationClass)
Get all of the values for the given annotation.
|
default <T extends java.lang.annotation.Annotation> |
findDeclaredAnnotation(java.lang.Class<T> annotationClass)
Get all of the values for the given annotation that are directly declared on the annotated element.
|
default java.util.Optional<java.lang.String> |
getAnnotationNameByStereotype(java.lang.Class<? extends java.lang.annotation.Annotation> stereotype)
Find the first annotation name for the given stereotype.
|
default java.util.Optional<java.lang.String> |
getAnnotationNameByStereotype(java.lang.String stereotype)
Find the first annotation name for the given stereotype.
|
default java.util.Set<java.lang.String> |
getAnnotationNames()
All the annotation names this metadata declares.
|
default java.util.List<java.lang.String> |
getAnnotationNamesByStereotype(java.lang.Class<? extends java.lang.annotation.Annotation> stereotype)
Resolve all of the annotation names that feature the given stereotype.
|
default java.util.List<java.lang.String> |
getAnnotationNamesByStereotype(java.lang.String stereotype)
Resolve all of the annotation names that feature the given stereotype.
|
default java.util.Optional<java.lang.Class<? extends java.lang.annotation.Annotation>> |
getAnnotationType(java.lang.String name)
Gets the type for a given annotation if it is present on the classpath.
|
default java.util.Optional<java.lang.Class<? extends java.lang.annotation.Annotation>> |
getAnnotationTypeByStereotype(java.lang.Class<? extends java.lang.annotation.Annotation> stereotype)
Find the first annotation name for the given stereotype.
|
default java.util.Optional<java.lang.Class<? extends java.lang.annotation.Annotation>> |
getAnnotationTypeByStereotype(java.lang.String stereotype)
Find the first annotation name for the given stereotype.
|
default java.util.List<java.lang.Class<? extends java.lang.annotation.Annotation>> |
getAnnotationTypesByStereotype(java.lang.Class<? extends java.lang.annotation.Annotation> stereotype)
Resolve all of the annotation names that feature the given stereotype.
|
default <T extends java.lang.annotation.Annotation> |
getAnnotationValuesByType(java.lang.Class<T> annotationType)
Gets all the annotation values by the given repeatable type.
|
default java.util.Optional<java.lang.String> |
getDeclaredAnnotationNameByStereotype(java.lang.String stereotype)
Find the first annotation name for the given stereotype.
|
default java.util.Set<java.lang.String> |
getDeclaredAnnotationNames()
All the declared annotation names this metadata declares.
|
default java.util.List<java.lang.String> |
getDeclaredAnnotationNamesByStereotype(java.lang.String stereotype)
Resolve all of the annotations names for the given stereotype that are declared annotations.
|
default java.util.Optional<java.lang.Class<? extends java.lang.annotation.Annotation>> |
getDeclaredAnnotationTypeByStereotype(java.lang.Class<? extends java.lang.annotation.Annotation> stereotype)
Find the first declared annotation name for the given stereotype.
|
default java.util.Optional<java.lang.Class<? extends java.lang.annotation.Annotation>> |
getDeclaredAnnotationTypeByStereotype(java.lang.String stereotype)
Find the first annotation name for the given stereotype.
|
default <T extends java.lang.annotation.Annotation> |
getDeclaredAnnotationValuesByType(java.lang.Class<T> annotationType)
Gets only declared annotation values by the given repeatable type.
|
default <T> java.util.Optional<T> |
getDefaultValue(java.lang.Class<? extends java.lang.annotation.Annotation> annotation,
java.lang.String member,
Argument<T> requiredType)
Return the default value for the given annotation member.
|
default <T> java.util.Optional<T> |
getDefaultValue(java.lang.Class<? extends java.lang.annotation.Annotation> annotation,
java.lang.String member,
java.lang.Class<T> requiredType)
Return the default value for the given annotation member.
|
default <T> java.util.Optional<T> |
getDefaultValue(java.lang.String annotation,
java.lang.String member,
Argument<T> requiredType)
Return the default value for the given annotation member.
|
default <T> java.util.Optional<T> |
getDefaultValue(java.lang.String annotation,
java.lang.String member,
java.lang.Class<T> requiredType)
Return the default value for the given annotation member.
|
default java.util.Map<java.lang.String,java.lang.Object> |
getDefaultValues(java.lang.String annotation)
Return the default values for the given annotation name.
|
default java.util.Optional<java.lang.Object> |
getValue(java.lang.Class<? extends java.lang.annotation.Annotation> annotation)
Get the value of default "value" the given annotation.
|
default <T> java.util.Optional<T> |
getValue(java.lang.Class<? extends java.lang.annotation.Annotation> annotation,
Argument<T> requiredType)
Get the value of default "value" the given annotation.
|
default <T> java.util.Optional<T> |
getValue(java.lang.Class<? extends java.lang.annotation.Annotation> annotation,
java.lang.Class<T> requiredType)
Get the value of default "value" the given annotation.
|
default java.util.Optional<java.lang.Object> |
getValue(java.lang.Class<? extends java.lang.annotation.Annotation> annotation,
java.lang.String member)
Get the value of the given annotation member.
|
default <T> java.util.Optional<T> |
getValue(java.lang.Class<? extends java.lang.annotation.Annotation> annotation,
java.lang.String member,
Argument<T> requiredType)
Get the value of the given annotation member.
|
default <T> java.util.Optional<T> |
getValue(java.lang.Class<? extends java.lang.annotation.Annotation> annotation,
java.lang.String member,
java.lang.Class<T> requiredType)
Get the value of the given annotation member.
|
default java.util.Optional<java.lang.Object> |
getValue(java.lang.String annotation)
Get the value of default "value" the given annotation.
|
default <T> java.util.Optional<T> |
getValue(java.lang.String annotation,
Argument<T> requiredType)
Get the value of default "value" the given annotation.
|
default <T> java.util.Optional<T> |
getValue(java.lang.String annotation,
java.lang.Class<T> requiredType)
Get the value of default "value" the given annotation.
|
default java.util.Optional<java.lang.Object> |
getValue(java.lang.String annotation,
java.lang.String member)
Get the value of the given annotation member.
|
default <T> java.util.Optional<T> |
getValue(java.lang.String annotation,
java.lang.String member,
Argument<T> requiredType)
Get the value of the given annotation member.
|
default <T> java.util.Optional<T> |
getValue(java.lang.String annotation,
java.lang.String member,
java.lang.Class<T> requiredType)
Get the value of the given annotation member.
|
default <T> OptionalValues<T> |
getValues(java.lang.Class<? extends java.lang.annotation.Annotation> annotation,
java.lang.Class<T> valueType)
Get all of the values for the given annotation.
|
default <T> OptionalValues<T> |
getValues(java.lang.String annotation,
java.lang.Class<T> valueType)
Get all of the values for the given annotation and type of the underlying values.
|
default boolean |
hasAnnotation(java.lang.Class<? extends java.lang.annotation.Annotation> annotation)
Checks whether this object has the given annotation on the object itself or inherited from a parent.
|
default boolean |
hasAnnotation(java.lang.String annotation)
Checks whether this object has the given annotation on the object itself or inherited from a parent.
|
default boolean |
hasDeclaredAnnotation(java.lang.Class<? extends java.lang.annotation.Annotation> annotation)
Checks whether this object has the given annotation directly declared on the object.
|
default boolean |
hasDeclaredAnnotation(java.lang.String annotation)
Checks whether this object has the given annotation directly declared on the object.
|
default boolean |
hasDeclaredStereotype(java.lang.Class<? extends java.lang.annotation.Annotation>... annotations)
Checks whether this object has any of the given stereotype directly declared on the object.
|
default boolean |
hasDeclaredStereotype(java.lang.Class<? extends java.lang.annotation.Annotation> stereotype)
Checks whether this object has the given stereotype directly declared on the object.
|
default boolean |
hasDeclaredStereotype(java.lang.String annotation)
Checks whether this object has the given annotation stereotype on the object itself and not inherited from a parent
|
default boolean |
hasSimpleAnnotation(java.lang.String annotation)
Checks whether the given annotation simple name (name without the package) is present in the annotations.
|
default boolean |
hasSimpleDeclaredAnnotation(java.lang.String annotation)
Checks whether the given annotation simple name (name without the package) is present in the declared annotations.
|
default boolean |
hasStereotype(java.lang.Class<? extends java.lang.annotation.Annotation>... annotations)
Check whether any of the given stereotypes is present.
|
default boolean |
hasStereotype(java.lang.Class<? extends java.lang.annotation.Annotation> annotation)
Checks whether this object has the given annotation stereotype on the object itself or inherited from a parent
|
default boolean |
hasStereotype(java.lang.String annotation)
Checks whether this object has the given annotation stereotype on the object itself or inherited from a parent
|
default boolean |
hasStereotype(java.lang.String[] annotations)
Check whether any of the given stereotypes is present.
|
default java.util.OptionalInt |
intValue(java.lang.Class<? extends java.lang.annotation.Annotation> annotation)
The value as an
OptionalInt for the given annotation and member. |
default java.util.OptionalInt |
intValue(java.lang.Class<? extends java.lang.annotation.Annotation> annotation,
java.lang.String member)
The value as an
OptionalInt for the given annotation and member. |
default java.util.OptionalInt |
intValue(java.lang.String annotation,
java.lang.String member)
The value as an
OptionalInt for the given annotation and member. |
default boolean |
isAnnotationPresent(java.lang.Class<? extends java.lang.annotation.Annotation> annotationClass)
Return whether an annotation is present.
|
default boolean |
isDeclaredAnnotationPresent(java.lang.Class<? extends java.lang.annotation.Annotation> annotationClass)
Variation of
AnnotationSource.isAnnotationPresent(Class) for declared annotations. |
default boolean |
isEmpty()
Is the annotation metadata empty.
|
default boolean |
isFalse(java.lang.Class<? extends java.lang.annotation.Annotation> annotation,
java.lang.String member)
Returns whether the value of the given member is true.
|
default boolean |
isFalse(java.lang.String annotation,
java.lang.String member)
Returns whether the value of the given member is true.
|
default boolean |
isPresent(java.lang.Class<? extends java.lang.annotation.Annotation> annotation,
java.lang.String member)
Returns whether the value of the given member is present.
|
default boolean |
isPresent(java.lang.String annotation,
java.lang.String member)
Returns whether the value of the given member is present.
|
default boolean |
isTrue(java.lang.Class<? extends java.lang.annotation.Annotation> annotation,
java.lang.String member)
Returns whether the value of the given member is true.
|
default boolean |
isTrue(java.lang.String annotation,
java.lang.String member)
Returns whether the value of the given member is true.
|
default java.util.OptionalLong |
longValue(java.lang.Class<? extends java.lang.annotation.Annotation> annotation,
java.lang.String member)
The value as an
OptionalLong for the given annotation and member. |
default java.util.OptionalLong |
longValue(java.lang.String annotation,
java.lang.String member)
The value as an
OptionalLong for the given annotation and member. |
default java.util.Optional<java.lang.String> |
stringValue(java.lang.Class<? extends java.lang.annotation.Annotation> annotation)
The value as an optional string for the given annotation and member.
|
default java.util.Optional<java.lang.String> |
stringValue(java.lang.Class<? extends java.lang.annotation.Annotation> annotation,
java.lang.String member)
The value as an optional string for the given annotation and member.
|
default java.util.Optional<java.lang.String> |
stringValue(java.lang.String annotation)
The value as an optional string for the given annotation and member.
|
default java.util.Optional<java.lang.String> |
stringValue(java.lang.String annotation,
java.lang.String member)
The value as an optional string for the given annotation and member.
|
default java.lang.String[] |
stringValues(java.lang.Class<? extends java.lang.annotation.Annotation> annotation)
The values as string array for the given annotation and member.
|
default java.lang.String[] |
stringValues(java.lang.Class<? extends java.lang.annotation.Annotation> annotation,
java.lang.String member)
The values as string array for the given annotation and member.
|
findAnnotation, findDeclaredAnnotation, getAnnotation, getAnnotation, getDeclaredAnnotation, getDeclaredAnnotation, synthesize, synthesizeAll, synthesizeAnnotationsByType, synthesizeDeclared, synthesizeDeclared, synthesizeDeclaredAnnotationsByType
static final AnnotationMetadata EMPTY_METADATA
static final java.lang.String VALUE_MEMBER
static final java.lang.String CLASS_NAME_SUFFIX
@NonNull default java.util.List<java.lang.String> getAnnotationNamesByStereotype(@Nullable java.lang.String stereotype)
stereotype
- The annotation names@NonNull default java.util.Set<java.lang.String> getAnnotationNames()
@NonNull default java.util.Set<java.lang.String> getDeclaredAnnotationNames()
@NonNull default java.util.List<java.lang.String> getDeclaredAnnotationNamesByStereotype(@Nullable java.lang.String stereotype)
stereotype
- The stereotype@NonNull default <T> OptionalValues<T> getValues(@NonNull java.lang.String annotation, @NonNull java.lang.Class<T> valueType)
T
- Generic typeannotation
- The annotation namevalueType
- valueTypeOptionalValues
default <T> java.util.Optional<T> getDefaultValue(@NonNull java.lang.String annotation, @NonNull java.lang.String member, @NonNull Argument<T> requiredType)
T
- The required generic typeannotation
- The annotationmember
- The memberrequiredType
- The required type@NonNull default <T extends java.lang.annotation.Annotation> java.util.List<AnnotationValue<T>> getAnnotationValuesByType(@NonNull java.lang.Class<T> annotationType)
T
- The annotation typeannotationType
- The annotation type@NonNull default <T extends java.lang.annotation.Annotation> java.util.List<AnnotationValue<T>> getDeclaredAnnotationValuesByType(@NonNull java.lang.Class<T> annotationType)
T
- The annotation typeannotationType
- The annotation typedefault boolean hasDeclaredAnnotation(@Nullable java.lang.String annotation)
annotation
- The annotationdefault boolean hasAnnotation(@Nullable java.lang.String annotation)
annotation
- The annotationdefault boolean hasSimpleAnnotation(@Nullable java.lang.String annotation)
annotation
- The annotationdefault boolean hasSimpleDeclaredAnnotation(@Nullable java.lang.String annotation)
annotation
- The annotationdefault boolean hasStereotype(@Nullable java.lang.String annotation)
Checks whether this object has the given annotation stereotype on the object itself or inherited from a parent
.
An annotation stereotype is a meta annotation potentially applied to another annotation
annotation
- The annotationdefault boolean hasDeclaredStereotype(@Nullable java.lang.String annotation)
Checks whether this object has the given annotation stereotype on the object itself and not inherited from a parent
.
An annotation stereotype is a meta annotation potentially applied to another annotation
annotation
- The annotation@NonNull default java.util.Map<java.lang.String,java.lang.Object> getDefaultValues(@NonNull java.lang.String annotation)
annotation
- The annotation namedefault <T> java.util.Optional<T> getDefaultValue(@NonNull java.lang.String annotation, @NonNull java.lang.String member, @NonNull java.lang.Class<T> requiredType)
T
- The required generic typeannotation
- The annotationmember
- The memberrequiredType
- The required typedefault <T> java.util.Optional<T> getDefaultValue(@NonNull java.lang.Class<? extends java.lang.annotation.Annotation> annotation, @NonNull java.lang.String member, @NonNull Argument<T> requiredType)
T
- The required generic typeannotation
- The annotationmember
- The memberrequiredType
- The required typedefault boolean isAnnotationPresent(@NonNull java.lang.Class<? extends java.lang.annotation.Annotation> annotationClass)
AnnotationSource
isAnnotationPresent
in interface AnnotationSource
annotationClass
- The annotation classAnnotationSource.isAnnotationPresent(Class)
default boolean isDeclaredAnnotationPresent(@NonNull java.lang.Class<? extends java.lang.annotation.Annotation> annotationClass)
AnnotationSource
AnnotationSource.isAnnotationPresent(Class)
for declared annotations.isDeclaredAnnotationPresent
in interface AnnotationSource
annotationClass
- The annotation classAnnotationSource.isAnnotationPresent(Class)
default <T> java.util.Optional<T> getDefaultValue(@NonNull java.lang.Class<? extends java.lang.annotation.Annotation> annotation, @NonNull java.lang.String member, @NonNull java.lang.Class<T> requiredType)
T
- The required generic typeannotation
- The annotationmember
- The memberrequiredType
- The required typedefault <T> java.util.Optional<T> getValue(@NonNull java.lang.Class<? extends java.lang.annotation.Annotation> annotation, @NonNull java.lang.String member, @NonNull java.lang.Class<T> requiredType)
T
- The valueannotation
- The annotation classmember
- The annotation memberrequiredType
- The required typeOptional
of the valuedefault <T> java.util.Optional<T> getValue(@NonNull java.lang.Class<? extends java.lang.annotation.Annotation> annotation, @NonNull java.lang.String member, @NonNull Argument<T> requiredType)
T
- The valueannotation
- The annotation classmember
- The annotation memberrequiredType
- The required typeOptional
of the valuedefault java.util.Optional<java.lang.String> getAnnotationNameByStereotype(@Nullable java.lang.String stereotype)
stereotype
- The stereotypedefault java.util.Optional<java.lang.String> getDeclaredAnnotationNameByStereotype(@Nullable java.lang.String stereotype)
stereotype
- The stereotypedefault java.util.Optional<java.lang.Class<? extends java.lang.annotation.Annotation>> getAnnotationTypeByStereotype(@NonNull java.lang.Class<? extends java.lang.annotation.Annotation> stereotype)
stereotype
- The stereotypedefault java.util.Optional<java.lang.Class<? extends java.lang.annotation.Annotation>> getDeclaredAnnotationTypeByStereotype(@NonNull java.lang.Class<? extends java.lang.annotation.Annotation> stereotype)
stereotype
- The stereotypedefault java.util.Optional<java.lang.Class<? extends java.lang.annotation.Annotation>> getDeclaredAnnotationTypeByStereotype(@Nullable java.lang.String stereotype)
stereotype
- The stereotypedefault java.util.Optional<java.lang.Class<? extends java.lang.annotation.Annotation>> getAnnotationType(@NonNull java.lang.String name)
name
- The type namedefault java.util.Optional<java.lang.Class<? extends java.lang.annotation.Annotation>> getAnnotationTypeByStereotype(@Nullable java.lang.String stereotype)
stereotype
- The stereotypedefault java.util.Optional<java.lang.String> getAnnotationNameByStereotype(@NonNull java.lang.Class<? extends java.lang.annotation.Annotation> stereotype)
stereotype
- The stereotype@NonNull default <T> OptionalValues<T> getValues(@NonNull java.lang.Class<? extends java.lang.annotation.Annotation> annotation, @NonNull java.lang.Class<T> valueType)
T
- Generic typeannotation
- The annotation namevalueType
- valueTypeOptionalValues
@NonNull default java.util.List<java.lang.String> getAnnotationNamesByStereotype(@NonNull java.lang.Class<? extends java.lang.annotation.Annotation> stereotype)
stereotype
- The annotation names@NonNull default java.util.List<java.lang.Class<? extends java.lang.annotation.Annotation>> getAnnotationTypesByStereotype(@NonNull java.lang.Class<? extends java.lang.annotation.Annotation> stereotype)
stereotype
- The annotation namesdefault <T extends java.lang.annotation.Annotation> java.util.Optional<AnnotationValue<T>> findAnnotation(@NonNull java.lang.Class<T> annotationClass)
findAnnotation
in interface AnnotationSource
T
- The annotation typeannotationClass
- The annotation nameAnnotationValue
default <T extends java.lang.annotation.Annotation> java.util.Optional<AnnotationValue<T>> findDeclaredAnnotation(@NonNull java.lang.Class<T> annotationClass)
findDeclaredAnnotation
in interface AnnotationSource
T
- The annotation typeannotationClass
- The annotation nameAnnotationValue
instancedefault <T> java.util.Optional<T> getValue(@NonNull java.lang.String annotation, @NonNull java.lang.String member, @NonNull java.lang.Class<T> requiredType)
T
- The valueannotation
- The annotation classmember
- The annotation memberrequiredType
- The required typeOptional
of the valuedefault <T> java.util.Optional<T> getValue(@NonNull java.lang.String annotation, @NonNull java.lang.String member, @NonNull Argument<T> requiredType)
T
- The valueannotation
- The annotation classmember
- The annotation memberrequiredType
- The required typeOptional
of the valuedefault java.util.OptionalLong longValue(@NonNull java.lang.String annotation, @NonNull java.lang.String member)
OptionalLong
for the given annotation and member.annotation
- The annotationmember
- The memberOptionalLong
valuedefault java.util.OptionalLong longValue(@NonNull java.lang.Class<? extends java.lang.annotation.Annotation> annotation, @NonNull java.lang.String member)
OptionalLong
for the given annotation and member.annotation
- The annotationmember
- The memberOptionalLong
valuedefault <E extends java.lang.Enum> java.util.Optional<E> enumValue(@NonNull java.lang.String annotation, java.lang.Class<E> enumType)
E
- The enum typeannotation
- The annotationenumType
- The enum typeOptional
enum valuedefault <E extends java.lang.Enum> java.util.Optional<E> enumValue(@NonNull java.lang.String annotation, @NonNull java.lang.String member, java.lang.Class<E> enumType)
E
- The enum typeannotation
- The annotationmember
- The annotation memberenumType
- The enum typeOptional
classdefault <E extends java.lang.Enum> java.util.Optional<E> enumValue(@NonNull java.lang.Class<? extends java.lang.annotation.Annotation> annotation, java.lang.Class<E> enumType)
E
- The enum typeannotation
- The annotationenumType
- The enum typeOptional
classdefault <E extends java.lang.Enum> java.util.Optional<E> enumValue(@NonNull java.lang.Class<? extends java.lang.annotation.Annotation> annotation, @NonNull java.lang.String member, java.lang.Class<E> enumType)
E
- The enum typeannotation
- The annotationmember
- The annotation memberenumType
- The enum typeOptional
classdefault <E extends java.lang.Enum> E[] enumValues(@NonNull java.lang.String annotation, java.lang.Class<E> enumType)
E
- The enum typeannotation
- The annotationenumType
- The enum typedefault <E extends java.lang.Enum> E[] enumValues(@NonNull java.lang.String annotation, @NonNull java.lang.String member, java.lang.Class<E> enumType)
E
- The enum typeannotation
- The annotationmember
- The annotation memberenumType
- The enum typedefault <E extends java.lang.Enum> E[] enumValues(@NonNull java.lang.Class<? extends java.lang.annotation.Annotation> annotation, java.lang.Class<E> enumType)
E
- The enum typeannotation
- The annotationenumType
- The enum typedefault <E extends java.lang.Enum> E[] enumValues(@NonNull java.lang.Class<? extends java.lang.annotation.Annotation> annotation, @NonNull java.lang.String member, java.lang.Class<E> enumType)
E
- The enum typeannotation
- The annotationmember
- The annotation memberenumType
- The enum type@NonNull default <T> java.lang.Class<T>[] classValues(@NonNull java.lang.String annotation)
T
- The type of the classannotation
- The annotationOptional
class@NonNull default <T> java.lang.Class<T>[] classValues(@NonNull java.lang.String annotation, @NonNull java.lang.String member)
T
- The type of the classannotation
- The annotationmember
- The annotation memberOptional
class@NonNull default <T> java.lang.Class<T>[] classValues(@NonNull java.lang.Class<? extends java.lang.annotation.Annotation> annotation)
T
- The type of the classannotation
- The annotationOptional
class@NonNull default <T> java.lang.Class<T>[] classValues(@NonNull java.lang.Class<? extends java.lang.annotation.Annotation> annotation, @NonNull java.lang.String member)
T
- The type of the classannotation
- The annotationmember
- The annotation memberOptional
classdefault java.util.Optional<java.lang.Class> classValue(@NonNull java.lang.String annotation)
annotation
- The annotationOptional
classdefault java.util.Optional<java.lang.Class> classValue(@NonNull java.lang.String annotation, @NonNull java.lang.String member)
annotation
- The annotationmember
- The annotation memberOptional
classdefault java.util.Optional<java.lang.Class> classValue(@NonNull java.lang.Class<? extends java.lang.annotation.Annotation> annotation)
annotation
- The annotationOptional
classdefault java.util.Optional<java.lang.Class> classValue(@NonNull java.lang.Class<? extends java.lang.annotation.Annotation> annotation, @NonNull java.lang.String member)
annotation
- The annotationmember
- The annotation memberOptional
classdefault java.util.OptionalInt intValue(@NonNull java.lang.String annotation, @NonNull java.lang.String member)
OptionalInt
for the given annotation and member.annotation
- The annotationmember
- The memberOptionalInt
valuedefault java.util.OptionalInt intValue(@NonNull java.lang.Class<? extends java.lang.annotation.Annotation> annotation, @NonNull java.lang.String member)
OptionalInt
for the given annotation and member.annotation
- The annotationmember
- The memberOptionalInt
valuedefault java.util.OptionalInt intValue(@NonNull java.lang.Class<? extends java.lang.annotation.Annotation> annotation)
OptionalInt
for the given annotation and member.annotation
- The annotationOptionalInt
valuedefault java.util.Optional<java.lang.String> stringValue(@NonNull java.lang.String annotation, @NonNull java.lang.String member)
annotation
- The annotationmember
- The memberdefault java.util.Optional<java.lang.String> stringValue(@NonNull java.lang.Class<? extends java.lang.annotation.Annotation> annotation, @NonNull java.lang.String member)
annotation
- The annotationmember
- The member@NonNull default java.util.Optional<java.lang.String> stringValue(@NonNull java.lang.Class<? extends java.lang.annotation.Annotation> annotation)
annotation
- The annotation@NonNull default java.util.Optional<java.lang.String> stringValue(@NonNull java.lang.String annotation)
annotation
- The annotationdefault java.util.Optional<java.lang.Boolean> booleanValue(@NonNull java.lang.String annotation, @NonNull java.lang.String member)
annotation
- The annotationmember
- The memberdefault java.util.Optional<java.lang.Boolean> booleanValue(@NonNull java.lang.Class<? extends java.lang.annotation.Annotation> annotation, @NonNull java.lang.String member)
annotation
- The annotationmember
- The member@NonNull default java.util.Optional<java.lang.Boolean> booleanValue(@NonNull java.lang.Class<? extends java.lang.annotation.Annotation> annotation)
annotation
- The annotation@NonNull default java.util.Optional<java.lang.Boolean> booleanValue(@NonNull java.lang.String annotation)
annotation
- The annotation@NonNull default java.lang.String[] stringValues(@NonNull java.lang.Class<? extends java.lang.annotation.Annotation> annotation, @NonNull java.lang.String member)
annotation
- The annotationmember
- The member@NonNull default java.lang.String[] stringValues(@NonNull java.lang.Class<? extends java.lang.annotation.Annotation> annotation)
annotation
- The annotation@NonNull default java.util.OptionalDouble doubleValue(@NonNull java.lang.String annotation, @NonNull java.lang.String member)
OptionalDouble
for the given annotation and member.annotation
- The annotationmember
- The memberOptionalDouble
value@NonNull default java.util.OptionalDouble doubleValue(@NonNull java.lang.Class<? extends java.lang.annotation.Annotation> annotation, @NonNull java.lang.String member)
OptionalDouble
for the given annotation and member.annotation
- The annotationmember
- The memberOptionalDouble
value@NonNull default java.util.OptionalDouble doubleValue(@NonNull java.lang.Class<? extends java.lang.annotation.Annotation> annotation)
OptionalDouble
for the given annotation and member.annotation
- The annotationOptionalDouble
value@NonNull default <T> java.util.Optional<T> getValue(@NonNull java.lang.String annotation, @NonNull java.lang.Class<T> requiredType)
T
- The valueannotation
- The annotation classrequiredType
- The required typeOptional
of the value@NonNull default java.util.Optional<java.lang.Object> getValue(@NonNull java.lang.String annotation, @NonNull java.lang.String member)
annotation
- The annotation classmember
- The annotation memberOptional
of the value@NonNull default java.util.Optional<java.lang.Object> getValue(@NonNull java.lang.Class<? extends java.lang.annotation.Annotation> annotation, @NonNull java.lang.String member)
annotation
- The annotation classmember
- The annotation memberOptional
of the valuedefault boolean isTrue(@NonNull java.lang.String annotation, @NonNull java.lang.String member)
annotation
- The annotation classmember
- The annotation memberdefault boolean isTrue(@NonNull java.lang.Class<? extends java.lang.annotation.Annotation> annotation, @NonNull java.lang.String member)
annotation
- The annotation classmember
- The annotation memberdefault boolean isPresent(@NonNull java.lang.String annotation, @NonNull java.lang.String member)
annotation
- The annotation classmember
- The annotation memberdefault boolean isPresent(@NonNull java.lang.Class<? extends java.lang.annotation.Annotation> annotation, @NonNull java.lang.String member)
annotation
- The annotation classmember
- The annotation memberdefault boolean isFalse(@NonNull java.lang.Class<? extends java.lang.annotation.Annotation> annotation, @NonNull java.lang.String member)
annotation
- The annotation classmember
- The annotation memberdefault boolean isFalse(@NonNull java.lang.String annotation, @NonNull java.lang.String member)
annotation
- The annotation classmember
- The annotation member@NonNull default java.util.Optional<java.lang.Object> getValue(@NonNull java.lang.String annotation)
annotation
- The annotation classOptional
of the value@NonNull default java.util.Optional<java.lang.Object> getValue(@NonNull java.lang.Class<? extends java.lang.annotation.Annotation> annotation)
annotation
- The annotation classOptional
of the value@NonNull default <T> java.util.Optional<T> getValue(@NonNull java.lang.Class<? extends java.lang.annotation.Annotation> annotation, @NonNull java.lang.Class<T> requiredType)
T
- Generic typeannotation
- The annotation classrequiredType
- requiredTypeOptional
of the value@NonNull default <T> java.util.Optional<T> getValue(@NonNull java.lang.Class<? extends java.lang.annotation.Annotation> annotation, @NonNull Argument<T> requiredType)
T
- Generic typeannotation
- The annotation classrequiredType
- requiredTypeOptional
of the value@NonNull default <T> java.util.Optional<T> getValue(@NonNull java.lang.String annotation, @NonNull Argument<T> requiredType)
T
- Generic typeannotation
- The annotation classrequiredType
- requiredTypeOptional
of the valuedefault boolean hasAnnotation(@Nullable java.lang.Class<? extends java.lang.annotation.Annotation> annotation)
annotation
- The annotationdefault boolean hasStereotype(@Nullable java.lang.Class<? extends java.lang.annotation.Annotation> annotation)
Checks whether this object has the given annotation stereotype on the object itself or inherited from a parent
.
An annotation stereotype is a meta annotation potentially applied to another annotation
annotation
- The annotationdefault boolean hasStereotype(@Nullable java.lang.Class<? extends java.lang.annotation.Annotation>... annotations)
annotations
- The annotationsdefault boolean hasStereotype(@Nullable java.lang.String[] annotations)
annotations
- The annotationsdefault boolean hasDeclaredAnnotation(@Nullable java.lang.Class<? extends java.lang.annotation.Annotation> annotation)
annotation
- The annotationdefault boolean hasDeclaredStereotype(@Nullable java.lang.Class<? extends java.lang.annotation.Annotation> stereotype)
stereotype
- The annotationdefault boolean hasDeclaredStereotype(@Nullable java.lang.Class<? extends java.lang.annotation.Annotation>... annotations)
annotations
- The annotationsdefault boolean isEmpty()