public interface TypedElement extends Element
PropertyElement
,
ClassElement
,
FieldElement
CLASS_NAME_SUFFIX, EMPTY_METADATA, VALUE_MEMBER
EMPTY
Modifier and Type | Method and Description |
---|---|
default int |
getArrayDimensions()
If the type is an array, the number of dimensions.
|
default ClassElement |
getGenericType()
Returns the generic type of the element.
|
ClassElement |
getType() |
default boolean |
isArray()
Is the type an array.
|
default boolean |
isPrimitive()
Whether the type is primitive.
|
annotate, annotate, annotate, annotate, getDocumentation, getName, getNativeType, getSimpleName, isAbstract, isFinal, isPrivate, isProtected, isPublic, isStatic
booleanValue, booleanValue, booleanValue, booleanValue, classValue, classValue, classValue, classValue, classValues, classValues, classValues, classValues, doubleValue, doubleValue, doubleValue, enumValue, enumValue, enumValue, enumValue, enumValues, enumValues, enumValues, enumValues, findAnnotation, findAnnotation, findDeclaredAnnotation, findDeclaredAnnotation, getAnnotation, getAnnotation, getAnnotationNameByStereotype, getAnnotationNameByStereotype, getAnnotationNames, getAnnotationNamesByStereotype, getAnnotationNamesByStereotype, getAnnotationType, getAnnotationTypeByStereotype, getAnnotationTypeByStereotype, getAnnotationTypesByStereotype, getAnnotationValuesByType, getDeclaredAnnotation, getDeclaredAnnotation, getDeclaredAnnotationNameByStereotype, getDeclaredAnnotationNames, getDeclaredAnnotationNamesByStereotype, getDeclaredAnnotationTypeByStereotype, getDeclaredAnnotationTypeByStereotype, getDeclaredAnnotationValuesByType, getDefaultValue, getDefaultValue, getDefaultValue, getDefaultValue, getDefaultValues, getValue, getValue, getValue, getValue, getValue, getValue, getValue, getValue, getValue, getValue, getValue, getValue, getValues, getValues, hasAnnotation, hasAnnotation, hasDeclaredAnnotation, hasDeclaredAnnotation, hasDeclaredStereotype, hasDeclaredStereotype, hasDeclaredStereotype, hasSimpleAnnotation, hasSimpleDeclaredAnnotation, hasStereotype, hasStereotype, hasStereotype, hasStereotype, intValue, intValue, intValue, isAnnotationPresent, isDeclaredAnnotationPresent, isEmpty, isFalse, isFalse, isPresent, isPresent, isTrue, isTrue, longValue, longValue, stringValue, stringValue, stringValue, stringValue, stringValues, stringValues, synthesize, synthesizeAll, synthesizeAnnotationsByType, synthesizeDeclared, synthesizeDeclared, synthesizeDeclaredAnnotationsByType
isDeclaredNonNull, isDeclaredNullable, isNonNull, isNullable
getAnnotationMetadata
@NonNull ClassElement getType()
@NonNull default ClassElement getGenericType()
getType()
as it returns
the actual type without erasure. Whilst getType()
is often needed to produce the correct byte code when
generating code via ASM, the getGenericType()
method is more useful for documentation and other types of code
generation.default boolean isPrimitive()
default boolean isArray()
default int getArrayDimensions()