Class JdkRecordComponentDetails
java.lang.Object
org.hibernate.models.internal.jdk.AbstractJdkAnnotationTarget
org.hibernate.models.internal.jdk.JdkRecordComponentDetails
- All Implemented Interfaces:
AnnotationTargetSupport,AnnotationTarget,MemberDetails,MutableAnnotationTarget,MutableMemberDetails,RecordComponentDetails
public class JdkRecordComponentDetails
extends AbstractJdkAnnotationTarget
implements RecordComponentDetails, MutableMemberDetails
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.hibernate.models.spi.AnnotationTarget
AnnotationTarget.AnnotationUsageProcessor<T,A extends Annotation>, AnnotationTarget.Kind Nested classes/interfaces inherited from interface org.hibernate.models.spi.MemberDetails
MemberDetails.Visibility -
Constructor Summary
ConstructorsConstructorDescriptionJdkRecordComponentDetails(RecordComponent recordComponent, ClassDetails declaringType, ModelsContext modelsContext) -
Method Summary
Modifier and TypeMethodDescription<A extends Annotation>
AnnotationDescriptor<A> Safe cast method for cases when the target is an annotation.Safe cast method for cases when the target is a record component.The class which declares this memberintAccess to the member modifier flags.getName()The name of the member.getType()The member type.booleanisArray()booleanisPlural()For member's with an associated type, whether that type considered plural.Access to the underlying Member.toJavaMember(Class<?> declaringClass, ClassLoading classLoading, ModelsContext modelContext) toString()Methods inherited from class org.hibernate.models.internal.jdk.AbstractJdkAnnotationTarget
addAnnotationUsage, clearAnnotationUsages, getModelContext, getUsageMapMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface org.hibernate.models.spi.AnnotationTarget
forEachAnnotationUsage, forEachAnnotationUsage, forEachDirectAnnotationUsage, fromAnnotations, fromContainers, fromSelfAndContainers, getNamedAnnotationUsage, getRepeatedAnnotationUsages, walkContainers, walkSelfAndContainersMethods inherited from interface org.hibernate.models.internal.AnnotationTargetSupport
forEachRepeatedAnnotationUsages, forEachRepeatedAnnotationUsages, getAnnotationUsage, getAnnotationUsage, getDirectAnnotationUsage, getDirectAnnotationUsage, getDirectAnnotationUsages, getMetaAnnotated, getNamedAnnotationUsage, getNamedAnnotationUsage, getNamedAnnotationUsage, getRepeatedAnnotationUsages, hasAnnotationUsage, hasDirectAnnotationUsage, locateAnnotationUsage, removeAnnotationUsage, replaceAnnotationUsageMethods inherited from interface org.hibernate.models.spi.MemberDetails
getAssociatedType, getContainer, getElementType, getMapKeyType, getVisibility, isField, isFinal, isStatic, isSynthetic, resolveRelativeAssociatedType, resolveRelativeClassType, resolveRelativeTypeMethods inherited from interface org.hibernate.models.spi.MutableAnnotationTarget
applyAnnotationUsage, replaceAnnotationUsageMethods inherited from interface org.hibernate.models.spi.RecordComponentDetails
getKind, isPersistable, resolveAttributeName
-
Constructor Details
-
JdkRecordComponentDetails
public JdkRecordComponentDetails(RecordComponent recordComponent, ClassDetails declaringType, ModelsContext modelsContext)
-
-
Method Details
-
getName
Description copied from interface:MemberDetailsThe name of the member. This would be the name of the method or field.- Specified by:
getNamein interfaceAnnotationTarget- Specified by:
getNamein interfaceMemberDetails
-
getType
Description copied from interface:MemberDetailsThe member type. May benull- Specified by:
getTypein interfaceMemberDetails- Returns:
- Returns one of:
- for a field, the field type
- for a getter method, the return type
- for a setter method, the argument type
- otherwise,
null
-
getDeclaringType
Description copied from interface:MemberDetailsThe class which declares this member- Specified by:
getDeclaringTypein interfaceMemberDetails
-
isPlural
public boolean isPlural()Description copied from interface:MemberDetailsFor member's with an associated type, whether that type considered plural.- Specified by:
isPluralin interfaceMemberDetails- Returns:
trueWhen the member has a type and that type is an array or a Map or Collection inheritor
-
isArray
public boolean isArray()- Specified by:
isArrayin interfaceMemberDetails
-
toJavaMember
Description copied from interface:MemberDetailsAccess to the underlying Member. May returnnull. May throw an exception.- Specified by:
toJavaMemberin interfaceMemberDetails- Specified by:
toJavaMemberin interfaceRecordComponentDetails- Returns:
- The underlying member, or
nullif there is no underlying member.
-
toJavaMember
public Member toJavaMember(Class<?> declaringClass, ClassLoading classLoading, ModelsContext modelContext) - Specified by:
toJavaMemberin interfaceMemberDetails- Specified by:
toJavaMemberin interfaceRecordComponentDetails
-
getModifiers
public int getModifiers()Description copied from interface:MemberDetailsAccess to the member modifier flags.- Specified by:
getModifiersin interfaceMemberDetails- See Also:
-
toString
-
asRecordComponentDetails
Description copied from interface:AnnotationTargetSafe cast method for cases when the target is a record component.- Specified by:
asRecordComponentDetailsin interfaceAnnotationTarget- Specified by:
asRecordComponentDetailsin interfaceAnnotationTargetSupport- Specified by:
asRecordComponentDetailsin interfaceRecordComponentDetails
-
asMemberDetails
Description copied from interface:AnnotationTarget- Specified by:
asMemberDetailsin interfaceAnnotationTarget- Specified by:
asMemberDetailsin interfaceAnnotationTargetSupport- Specified by:
asMemberDetailsin interfaceMemberDetails- Specified by:
asMemberDetailsin interfaceMutableAnnotationTarget- Specified by:
asMemberDetailsin interfaceMutableMemberDetails
-
asFieldDetails
Description copied from interface:AnnotationTarget- Specified by:
asFieldDetailsin interfaceAnnotationTarget- Specified by:
asFieldDetailsin interfaceAnnotationTargetSupport- Specified by:
asFieldDetailsin interfaceRecordComponentDetails
-
asMethodDetails
Description copied from interface:AnnotationTarget- Specified by:
asMethodDetailsin interfaceAnnotationTarget- Specified by:
asMethodDetailsin interfaceAnnotationTargetSupport- Specified by:
asMethodDetailsin interfaceRecordComponentDetails
-
asClassDetails
Description copied from interface:AnnotationTarget- Specified by:
asClassDetailsin interfaceAnnotationTarget- Specified by:
asClassDetailsin interfaceAnnotationTargetSupport- Specified by:
asClassDetailsin interfaceMemberDetails- Specified by:
asClassDetailsin interfaceMutableAnnotationTarget- Specified by:
asClassDetailsin interfaceMutableMemberDetails
-
asAnnotationDescriptor
Description copied from interface:AnnotationTargetSafe cast method for cases when the target is an annotation.- Specified by:
asAnnotationDescriptorin interfaceAnnotationTarget- Specified by:
asAnnotationDescriptorin interfaceAnnotationTargetSupport- Specified by:
asAnnotationDescriptorin interfaceMemberDetails- Specified by:
asAnnotationDescriptorin interfaceMutableMemberDetails
-