java.lang.Object
java.lang.Record
org.litebridge.orm.persistence.MappingPlan.FieldMapping
- Enclosing class:
MappingPlan
public static record MappingPlan.FieldMapping(int index, FieldAccessor accessor, Class<?> fieldType, boolean isRelatedDto, boolean isNestedDto, @Nullable FieldAccessor relatedPkAccessor)
extends Record
-
Constructor Summary
ConstructorsConstructorDescriptionFieldMapping(int index, FieldAccessor accessor, Class<?> fieldType, boolean isRelatedDto, boolean isNestedDto, @Nullable FieldAccessor relatedPkAccessor) Creates an instance of aFieldMappingrecord class. -
Method Summary
Modifier and TypeMethodDescriptionaccessor()Returns the value of theaccessorrecord component.final booleanIndicates whether some other object is "equal to" this one.Class<?> Returns the value of thefieldTyperecord component.final inthashCode()Returns a hash code value for this object.intindex()Returns the value of theindexrecord component.booleanReturns the value of theisNestedDtorecord component.booleanReturns the value of theisRelatedDtorecord component.@Nullable FieldAccessorReturns the value of therelatedPkAccessorrecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
FieldMapping
public FieldMapping(int index, FieldAccessor accessor, Class<?> fieldType, boolean isRelatedDto, boolean isNestedDto, @Nullable FieldAccessor relatedPkAccessor) Creates an instance of aFieldMappingrecord class.- Parameters:
index- the value for theindexrecord componentaccessor- the value for theaccessorrecord componentfieldType- the value for thefieldTyperecord componentisRelatedDto- the value for theisRelatedDtorecord componentisNestedDto- the value for theisNestedDtorecord componentrelatedPkAccessor- the value for therelatedPkAccessorrecord component
-
-
Method Details
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with '=='. -
index
public int index()Returns the value of theindexrecord component.- Returns:
- the value of the
indexrecord component
-
accessor
Returns the value of theaccessorrecord component.- Returns:
- the value of the
accessorrecord component
-
fieldType
Returns the value of thefieldTyperecord component.- Returns:
- the value of the
fieldTyperecord component
-
isRelatedDto
public boolean isRelatedDto()Returns the value of theisRelatedDtorecord component.- Returns:
- the value of the
isRelatedDtorecord component
-
isNestedDto
public boolean isNestedDto()Returns the value of theisNestedDtorecord component.- Returns:
- the value of the
isNestedDtorecord component
-