Record Class UserProfileResponse

java.lang.Object
java.lang.Record
api.mpba.rastvdmy.dto.response.UserProfileResponse
Record Components:
id - The unique identifier of the user.
name - The name of the user.
surname - The surname of the user.
dateOfBirth - The date of birth of the user.
countryOfOrigin - The country of origin of the user.
email - The email address of the user.
password - The password of the user.
phoneNumber - The phone number of the user.
avatar - The avatar of the user.
status - The status of the user.
role - The role of the user in the system.

public record UserProfileResponse(UUID id, String name, String surname, String dateOfBirth, String countryOfOrigin, String email, String password, String phoneNumber, String avatar, UserStatus status, UserRole role) extends Record
This class represents a response for a user profile in the banking system.
  • Constructor Details

    • UserProfileResponse

      public UserProfileResponse(UUID id, String name, String surname, String dateOfBirth, String countryOfOrigin, String email, String password, String phoneNumber, String avatar, UserStatus status, UserRole role)
      Creates an instance of a UserProfileResponse record class.
      Parameters:
      id - the value for the id record component
      name - the value for the name record component
      surname - the value for the surname record component
      dateOfBirth - the value for the dateOfBirth record component
      countryOfOrigin - the value for the countryOfOrigin record component
      email - the value for the email record component
      password - the value for the password record component
      phoneNumber - the value for the phoneNumber record component
      avatar - the value for the avatar record component
      status - the value for the status record component
      role - the value for the role record component
  • Method Details

    • toString

      public final String 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.
      Specified by:
      toString in class Record
      Returns:
      a string representation of this object
    • 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.
      Specified by:
      hashCode in class Record
      Returns:
      a hash code value for this object
    • equals

      public final boolean equals(Object o)
      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 with Objects::equals(Object,Object).
      Specified by:
      equals in class Record
      Parameters:
      o - the object with which to compare
      Returns:
      true if this object is the same as the o argument; false otherwise.
    • id

      public UUID id()
      Returns the value of the id record component.
      Returns:
      the value of the id record component
    • name

      public String name()
      Returns the value of the name record component.
      Returns:
      the value of the name record component
    • surname

      public String surname()
      Returns the value of the surname record component.
      Returns:
      the value of the surname record component
    • dateOfBirth

      public String dateOfBirth()
      Returns the value of the dateOfBirth record component.
      Returns:
      the value of the dateOfBirth record component
    • countryOfOrigin

      public String countryOfOrigin()
      Returns the value of the countryOfOrigin record component.
      Returns:
      the value of the countryOfOrigin record component
    • email

      public String email()
      Returns the value of the email record component.
      Returns:
      the value of the email record component
    • password

      public String password()
      Returns the value of the password record component.
      Returns:
      the value of the password record component
    • phoneNumber

      public String phoneNumber()
      Returns the value of the phoneNumber record component.
      Returns:
      the value of the phoneNumber record component
    • avatar

      public String avatar()
      Returns the value of the avatar record component.
      Returns:
      the value of the avatar record component
    • status

      public UserStatus status()
      Returns the value of the status record component.
      Returns:
      the value of the status record component
    • role

      public UserRole role()
      Returns the value of the role record component.
      Returns:
      the value of the role record component