Package web.sportflow.user
Record Class RegistrationDTO
java.lang.Object
java.lang.Record
web.sportflow.user.RegistrationDTO
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionemail()Returns the value of theemailrecord component.final booleanIndicates whether some other object is "equal to" this one.Returns the value of thefirstnamerecord component.final inthashCode()Returns a hash code value for this object.height()Returns the value of theheightrecord component.lastname()Returns the value of thelastnamerecord component.password()Returns the value of thepasswordrecord component.sex()Returns the value of thesexrecord component.final StringtoString()Returns a string representation of this record class.weight()Returns the value of theweightrecord component.
-
Constructor Details
-
RegistrationDTO
public RegistrationDTO(String email, String password, String firstname, String lastname, Sex sex, Double weight, Double height) Creates an instance of aRegistrationDTOrecord class.- Parameters:
email- the value for theemailrecord componentpassword- the value for thepasswordrecord componentfirstname- the value for thefirstnamerecord componentlastname- the value for thelastnamerecord componentsex- the value for thesexrecord componentweight- the value for theweightrecord componentheight- the value for theheightrecord 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. All components in this record class are compared withObjects::equals(Object,Object). -
email
Returns the value of theemailrecord component.- Returns:
- the value of the
emailrecord component
-
password
Returns the value of thepasswordrecord component.- Returns:
- the value of the
passwordrecord component
-
firstname
Returns the value of thefirstnamerecord component.- Returns:
- the value of the
firstnamerecord component
-
lastname
Returns the value of thelastnamerecord component.- Returns:
- the value of the
lastnamerecord component
-
sex
Returns the value of thesexrecord component.- Returns:
- the value of the
sexrecord component
-
weight
Returns the value of theweightrecord component.- Returns:
- the value of the
weightrecord component
-
height
Returns the value of theheightrecord component.- Returns:
- the value of the
heightrecord component
-