@Internal public class SourcePersistentEntity extends AbstractPersistentEntity implements PersistentEntity, io.micronaut.inject.ast.TypedElement
PersistentEntity that operates on the sources.| Constructor and Description |
|---|
SourcePersistentEntity(io.micronaut.inject.ast.ClassElement classElement,
java.util.function.Function<io.micronaut.inject.ast.ClassElement,SourcePersistentEntity> entityResolver)
Default constructor.
|
| Modifier and Type | Method and Description |
|---|---|
io.micronaut.inject.ast.ClassElement |
getClassElement() |
SourcePersistentProperty[] |
getCompositeIdentity()
The composite id.
|
SourcePersistentProperty |
getIdentity()
Returns the identity of the instance.
|
SourcePersistentProperty |
getIdentityByName(java.lang.String name)
Obtains an identity PersistentProperty instance by name.
|
SourcePersistentProperty |
getIdOrVersionPropertyByName(java.lang.String name)
Obtains a PersistentProperty representing id or version property by name.
|
java.lang.String |
getName()
The entity name including any package prefix.
|
java.lang.Object |
getNativeType() |
PersistentEntity |
getParentEntity()
Returns the parent entity of this entity.
|
java.util.List<SourcePersistentProperty> |
getPersistentProperties()
A list of properties to be persisted.
|
java.util.List<java.lang.String> |
getPersistentPropertyNames()
A list of property names that a persistent.
|
SourcePersistentProperty |
getPropertyByName(java.lang.String name)
Obtains a PersistentProperty instance by name.
|
java.lang.String |
getSimpleName() |
io.micronaut.inject.ast.ClassElement |
getType() |
SourcePersistentProperty |
getVersion()
Returns the version property.
|
boolean |
hasCompositeIdentity()
Has composite identity.
|
boolean |
hasIdentity()
Has identity.
|
boolean |
isOwningEntity(PersistentEntity owner)
Returns whether the specified entity asserts ownership over this
entity.
|
boolean |
isProtected() |
boolean |
isPublic() |
java.lang.String |
toString() |
equals, findNamingStrategy, getAliasName, getAnnotationMetadata, getNamingStrategy, getPersistedName, hashCodeclone, finalize, getClass, notify, notifyAll, wait, wait, waitfindNamingStrategy, getAliasName, getAssociations, getDecapitalizedName, getEmbedded, getNamingStrategy, getPath, getPropertyByPath, getPropertyPath, getRootEntity, isEmbeddable, isRoot, isVersioned, of, ofgetPersistedNamegetArrayDimensions, getGenericType, isArray, isPrimitiveannotate, annotate, annotate, annotate, annotate, getDescription, getDescription, getDocumentation, getModifiers, isAbstract, isFinal, isPackagePrivate, isPrivate, isStatic, removeAnnotation, removeAnnotation, removeAnnotationIf, removeStereotype, removeStereotypebooleanValue, 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, getAnnotationType, getAnnotationTypeByStereotype, getAnnotationTypeByStereotype, getAnnotationTypesByStereotype, getAnnotationTypesByStereotype, getAnnotationTypesByStereotype, getAnnotationValuesByType, getDeclaredAnnotation, getDeclaredAnnotation, getDeclaredAnnotationNameByStereotype, getDeclaredAnnotationNames, getDeclaredAnnotationNamesByStereotype, getDeclaredAnnotationTypeByStereotype, getDeclaredAnnotationTypeByStereotype, getDeclaredAnnotationValuesByType, getDeclaredMetadata, 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, hasPropertyExpressions, 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, stringValues, stringValues, synthesize, synthesize, synthesizeAll, synthesizeAnnotationsByType, synthesizeDeclared, synthesizeDeclared, synthesizeDeclared, synthesizeDeclaredAnnotationsByTypegetValues, hasDeclaredStereotype, isAnnotationPresent, isDeclaredAnnotationPresentpublic SourcePersistentEntity(@NonNull
io.micronaut.inject.ast.ClassElement classElement,
@NonNull
java.util.function.Function<io.micronaut.inject.ast.ClassElement,SourcePersistentEntity> entityResolver)
classElement - The class elemententityResolver - The entity resolver to resolve any additional entities such as associations@NonNull public java.lang.String getName()
PersistentEntitygetName in interface io.micronaut.core.naming.NamedgetName in interface PersistentEntitygetName in interface io.micronaut.inject.ast.Elementpublic java.lang.String getSimpleName()
getSimpleName in interface PersistentEntitygetSimpleName in interface io.micronaut.inject.ast.Elementpublic boolean isProtected()
isProtected in interface io.micronaut.inject.ast.Elementpublic boolean isPublic()
isPublic in interface io.micronaut.inject.ast.Elementpublic java.lang.Object getNativeType()
getNativeType in interface io.micronaut.inject.ast.Elementpublic boolean hasCompositeIdentity()
PersistentEntityhasCompositeIdentity in interface PersistentEntitypublic boolean hasIdentity()
PersistentEntityhasIdentity in interface PersistentEntity@Nullable public SourcePersistentProperty[] getCompositeIdentity()
PersistentEntitygetCompositeIdentity in interface PersistentEntity@Nullable public SourcePersistentProperty getIdentity()
PersistentEntitygetIdentity in interface PersistentEntity@Nullable public SourcePersistentProperty getVersion()
PersistentEntitygetVersion in interface PersistentEntity@NonNull public java.util.List<SourcePersistentProperty> getPersistentProperties()
PersistentEntitygetPersistentProperties in interface PersistentEntity@Nullable public SourcePersistentProperty getPropertyByName(java.lang.String name)
PersistentEntitygetPropertyByName in interface PersistentEntityname - The name of the property@Nullable public SourcePersistentProperty getIdentityByName(java.lang.String name)
PersistentEntitygetIdentityByName in interface PersistentEntityname - The name of the identity propertypublic SourcePersistentProperty getIdOrVersionPropertyByName(java.lang.String name)
name - The name of the id or version property@NonNull public java.util.List<java.lang.String> getPersistentPropertyNames()
PersistentEntitygetPersistentPropertyNames in interface PersistentEntitypublic boolean isOwningEntity(PersistentEntity owner)
PersistentEntityisOwningEntity in interface PersistentEntityowner - The owning entity@Nullable public PersistentEntity getParentEntity()
PersistentEntitygetParentEntity in interface PersistentEntitypublic io.micronaut.inject.ast.ClassElement getClassElement()
@NonNull public io.micronaut.inject.ast.ClassElement getType()
getType in interface io.micronaut.inject.ast.TypedElementpublic java.lang.String toString()
toString in class java.lang.Object