java.lang.Object
java.lang.Record
jakarta.data.metamodel.impl.SortableAttributeRecord<T>
- Record Components:
name- the name of the attribute
- All Implemented Interfaces:
Attribute<T>,SortableAttribute<T>
public record SortableAttributeRecord<T>(String name)
extends Record
implements SortableAttribute<T>
Record type implementing
SortableAttribute.
This may be used to simplify implementation of the static metamodel.-
Constructor Summary
ConstructorsConstructorDescriptionCreates an instance of aSortableAttributeRecordrecord class. -
Method Summary
Modifier and TypeMethodDescriptionasc()Obtain a request for an ascendingSortbased on the entity attribute.desc()Obtain a request for a descendingSortbased on the entity attribute.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.name()Returns the value of thenamerecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
SortableAttributeRecord
Creates an instance of aSortableAttributeRecordrecord class.- Parameters:
name- the value for thenamerecord component
-
-
Method Details
-
asc
Description copied from interface:SortableAttributeObtain a request for an ascendingSortbased on the entity attribute.- Specified by:
ascin interfaceSortableAttribute<T>- Returns:
- a request for an ascending sort on the entity attribute.
-
desc
Description copied from interface:SortableAttributeObtain a request for a descendingSortbased on the entity attribute.- Specified by:
descin interfaceSortableAttribute<T>- Returns:
- a request for a descending sort on the entity attribute.
-
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. All components in this record class are compared withObjects::equals(Object,Object). -
name
Returns the value of thenamerecord component.
-