Class AbstractJavaElement
java.lang.Object
io.micronaut.inject.ast.annotation.AbstractAnnotationElement
io.micronaut.annotation.processing.visitor.AbstractJavaElement
- All Implemented Interfaces:
ElementProvider, io.micronaut.core.annotation.AnnotatedElement, io.micronaut.core.annotation.AnnotationMetadata, io.micronaut.core.annotation.AnnotationMetadataDelegate, io.micronaut.core.annotation.AnnotationMetadataProvider, io.micronaut.core.annotation.AnnotationSource, io.micronaut.core.naming.Described, io.micronaut.core.naming.Named, io.micronaut.inject.ast.annotation.MutableAnnotationMetadataDelegate<io.micronaut.inject.ast.Element>, io.micronaut.inject.ast.Element
- Direct Known Subclasses:
AbstractTypeAwareJavaElement, JavaPackageElement
@Internal
public abstract class AbstractJavaElement
extends io.micronaut.inject.ast.annotation.AbstractAnnotationElement
implements ElementProvider
An abstract class for other elements to extend from.
- Since:
- 1.0
-
Field Summary
FieldsFields inherited from class io.micronaut.inject.ast.annotation.AbstractAnnotationElement
elementAnnotationMetadataFactory, presetAnnotationMetadataFields inherited from interface io.micronaut.core.annotation.AnnotationMetadata
CLASS_NAME_SUFFIX, EMPTY_METADATA, VALUE_MEMBERFields inherited from interface io.micronaut.core.annotation.AnnotationSource
EMPTYFields inherited from interface io.micronaut.inject.ast.Element
EMPTY_ELEMENT_ARRAYFields inherited from interface io.micronaut.inject.ast.annotation.MutableAnnotationMetadataDelegate
EMPTY -
Method Summary
Modifier and TypeMethodDescriptionprotected abstract AbstractJavaElementcopyThis()protected voidcopyValues(AbstractJavaElement element) element()booleangetDocumentation(boolean parse) Set<io.micronaut.inject.ast.ElementModifier> getName()inthashCode()booleanbooleanisFinal()booleanbooleanbooleanbooleanisPublic()booleanisStatic()protected final AbstractJavaElementmakeCopy()protected final io.micronaut.inject.ast.ClassElementnewClassElement(@Nullable JavaNativeElement owner, TypeMirror type, Map<String, io.micronaut.inject.ast.ClassElement> declaredElementTypeArguments) Obtain the ClassElement for the given mirror.protected final io.micronaut.inject.ast.ClassElementnewClassElement(@Nullable JavaNativeElement owner, TypeMirror type, Map<String, io.micronaut.inject.ast.ClassElement> declaredElementTypeArguments, @Nullable String doc) Obtain the ClassElement for the given mirror.protected final io.micronaut.inject.ast.ClassElementnewClassElement(TypeMirror type, Map<String, io.micronaut.inject.ast.ClassElement> declaredElementTypeArguments) Obtain the ClassElement for the given mirror.resolveTypeArguments(ExecutableElement executableElement, Map<String, io.micronaut.inject.ast.ClassElement> parentTypeArguments) resolveTypeArguments(TypeElement typeElement, @Nullable List<? extends TypeMirror> typeMirrorArguments) toString()io.micronaut.inject.ast.ElementwithAnnotationMetadata(io.micronaut.core.annotation.AnnotationMetadata annotationMetadata) Methods inherited from class io.micronaut.inject.ast.annotation.AbstractAnnotationElement
annotate, annotate, annotate, annotate, annotate, getAnnotationMetadata, getAnnotationMetadataToWrite, getElementAnnotationMetadata, getElementAnnotationMetadataFactory, removeAnnotation, removeAnnotation, removeAnnotationIf, removeStereotype, removeStereotypeMethods inherited from interface io.micronaut.core.annotation.AnnotatedElement
isDeclaredNonNull, isDeclaredNullable, isNonNull, isNullableMethods inherited from interface io.micronaut.core.annotation.AnnotationMetadata
enumValuesSet, enumValuesSet, getValues, hasDeclaredStereotype, hasEvaluatedExpressions, hasStereotypeNonRepeating, isAnnotationPresent, isDeclaredAnnotationPresentMethods inherited from interface io.micronaut.core.annotation.AnnotationMetadataDelegate
booleanValue, booleanValue, booleanValue, booleanValue, classValue, classValue, classValue, classValue, classValues, classValues, classValues, classValues, copyAnnotationMetadata, doubleValue, doubleValue, doubleValue, enumValue, enumValue, enumValue, enumValue, enumValues, enumValues, enumValues, enumValues, findAnnotation, findAnnotation, findDeclaredAnnotation, findDeclaredAnnotation, findRepeatableAnnotation, findRepeatableAnnotation, getAnnotation, getAnnotation, getAnnotationNameByStereotype, getAnnotationNameByStereotype, getAnnotationNames, getAnnotationNamesByStereotype, getAnnotationNamesByStereotype, getAnnotationType, getAnnotationType, getAnnotationTypeByStereotype, getAnnotationTypeByStereotype, getAnnotationTypesByStereotype, getAnnotationTypesByStereotype, getAnnotationTypesByStereotype, getAnnotationValuesByName, getAnnotationValuesByStereotype, getAnnotationValuesByType, getDeclaredAnnotation, getDeclaredAnnotation, getDeclaredAnnotationNameByStereotype, getDeclaredAnnotationNames, getDeclaredAnnotationNamesByStereotype, getDeclaredAnnotationTypeByStereotype, getDeclaredAnnotationTypeByStereotype, getDeclaredAnnotationValuesByName, getDeclaredAnnotationValuesByType, getDeclaredMetadata, getDeclaredStereotypeAnnotationNames, getDefaultValue, getDefaultValue, getDefaultValue, getDefaultValue, getDefaultValues, getStereotypeAnnotationNames, getTargetAnnotationMetadata, getValue, getValue, getValue, getValue, getValue, getValue, getValue, getValue, getValue, getValue, getValue, getValue, getValues, getValues, hasAnnotation, hasAnnotation, hasDeclaredAnnotation, hasDeclaredAnnotation, hasDeclaredStereotype, hasDeclaredStereotype, hasDeclaredStereotype, hasPropertyExpressions, hasSimpleAnnotation, hasSimpleDeclaredAnnotation, hasStereotype, hasStereotype, hasStereotype, hasStereotype, intValue, intValue, intValue, isAnnotationPresent, isDeclaredAnnotationPresent, isEmpty, isFalse, isFalse, isPresent, isPresent, isRepeatableAnnotation, isRepeatableAnnotation, isTrue, isTrue, longValue, longValue, stringValue, stringValue, stringValue, stringValue, stringValues, stringValues, stringValues, stringValues, synthesize, synthesize, synthesizeAll, synthesizeAnnotationsByType, synthesizeDeclared, synthesizeDeclared, synthesizeDeclared, synthesizeDeclaredAnnotationsByTypeMethods inherited from interface io.micronaut.inject.ast.Element
getDescription, getDescription, getDocumentation, getSimpleName, isSynthetic
-
Field Details
-
visitorContext
-
-
Method Details
-
element
- Specified by:
elementin interfaceElementProvider- Returns:
- The native element.
-
copyThis
- Returns:
- copy of this element
-
copyValues
- Parameters:
element- the values to be copied to
-
makeCopy
-
withAnnotationMetadata
public io.micronaut.inject.ast.Element withAnnotationMetadata(io.micronaut.core.annotation.AnnotationMetadata annotationMetadata) - Specified by:
withAnnotationMetadatain interfaceio.micronaut.inject.ast.Element
-
isPackagePrivate
public boolean isPackagePrivate()- Specified by:
isPackagePrivatein interfaceio.micronaut.inject.ast.Element
-
getName
- Specified by:
getNamein interfaceio.micronaut.inject.ast.Element- Specified by:
getNamein interfaceio.micronaut.core.naming.Named
-
getModifiers
- Specified by:
getModifiersin interfaceio.micronaut.inject.ast.Element
-
getDocumentation
-
isAbstract
public boolean isAbstract()- Specified by:
isAbstractin interfaceio.micronaut.inject.ast.Element
-
isStatic
public boolean isStatic()- Specified by:
isStaticin interfaceio.micronaut.inject.ast.Element
-
isPublic
public boolean isPublic()- Specified by:
isPublicin interfaceio.micronaut.inject.ast.Element
-
isPrivate
public boolean isPrivate()- Specified by:
isPrivatein interfaceio.micronaut.inject.ast.Element
-
isFinal
public boolean isFinal()- Specified by:
isFinalin interfaceio.micronaut.inject.ast.Element
-
isProtected
public boolean isProtected()- Specified by:
isProtectedin interfaceio.micronaut.inject.ast.Element
-
getNativeType
- Specified by:
getNativeTypein interfaceio.micronaut.inject.ast.Element
-
toString
-
newClassElement
protected final io.micronaut.inject.ast.ClassElement newClassElement(@Nullable JavaNativeElement owner, TypeMirror type, Map<String, io.micronaut.inject.ast.ClassElement> declaredElementTypeArguments) Obtain the ClassElement for the given mirror.- Parameters:
owner- The ownertype- The typedeclaredElementTypeArguments- The type arguments of the declaring element (method, class)- Returns:
- The class element
-
newClassElement
protected final io.micronaut.inject.ast.ClassElement newClassElement(@Nullable JavaNativeElement owner, TypeMirror type, Map<String, io.micronaut.inject.ast.ClassElement> declaredElementTypeArguments, @Nullable String doc) Obtain the ClassElement for the given mirror.- Parameters:
owner- The ownertype- The typedeclaredElementTypeArguments- The type arguments of the declaring element (method, class)doc- The optional documentation- Returns:
- The class element
-
newClassElement
protected final io.micronaut.inject.ast.ClassElement newClassElement(TypeMirror type, Map<String, io.micronaut.inject.ast.ClassElement> declaredElementTypeArguments) Obtain the ClassElement for the given mirror.- Parameters:
type- The typedeclaredElementTypeArguments- The type arguments of the declaring element (method, class)- Returns:
- The class element
-
resolveTypeArguments
protected final Map<String, io.micronaut.inject.ast.ClassElement> resolveTypeArguments(TypeElement typeElement, @Nullable List<? extends TypeMirror> typeMirrorArguments) -
resolveTypeArguments
protected final Map<String, io.micronaut.inject.ast.ClassElement> resolveTypeArguments(ExecutableElement executableElement, Map<String, io.micronaut.inject.ast.ClassElement> parentTypeArguments) -
equals
-
hashCode
-