Record Class UserResponseDTO
java.lang.Object
java.lang.Record
br.com.receitaquedoimenos.ReceitaQueDoiMenos.models.user.UserResponseDTO
- Record Components:
name- String referente ao nome do usuárioemail- String referente ao email do usuáriocreatedMealsID- Lista com ID's das receitas criadasfavoriteMealsID- Lista com ID's das receitas favoritadascreatedDrinksID- Lista com ID's dos drinks criadosfavoriteDrinkID- Lista com ID's dos drinks favoritados
public record UserResponseDTO(String id, String name, String email, ArrayList<String> createdMealsID, ArrayList<String> favoriteMealsID, ArrayList<String> createdDrinksID, ArrayList<String> favoriteDrinkID)
extends Record
Informações referentes a um usuário criado ou atualizados requeridos dentro do sistema
- Author:
- Pedro Henrique Pereira de Oliveira
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionReturns the value of thecreatedDrinksIDrecord component.Returns the value of thecreatedMealsIDrecord component.email()Returns the value of theemailrecord component.final booleanIndicates whether some other object is "equal to" this one.Returns the value of thefavoriteDrinkIDrecord component.Returns the value of thefavoriteMealsIDrecord component.final inthashCode()Returns a hash code value for this object.id()Returns the value of theidrecord component.name()Returns the value of thenamerecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
UserResponseDTO
public UserResponseDTO(String id, String name, String email, ArrayList<String> createdMealsID, ArrayList<String> favoriteMealsID, ArrayList<String> createdDrinksID, ArrayList<String> favoriteDrinkID) Creates an instance of aUserResponseDTOrecord class.- Parameters:
id- the value for theidrecord componentname- the value for thenamerecord componentemail- the value for theemailrecord componentcreatedMealsID- the value for thecreatedMealsIDrecord componentfavoriteMealsID- the value for thefavoriteMealsIDrecord componentcreatedDrinksID- the value for thecreatedDrinksIDrecord componentfavoriteDrinkID- the value for thefavoriteDrinkIDrecord 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). -
id
Returns the value of theidrecord component.- Returns:
- the value of the
idrecord component
-
name
Returns the value of thenamerecord component.- Returns:
- the value of the
namerecord component
-
email
Returns the value of theemailrecord component.- Returns:
- the value of the
emailrecord component
-
createdMealsID
Returns the value of thecreatedMealsIDrecord component.- Returns:
- the value of the
createdMealsIDrecord component
-
favoriteMealsID
Returns the value of thefavoriteMealsIDrecord component.- Returns:
- the value of the
favoriteMealsIDrecord component
-
createdDrinksID
Returns the value of thecreatedDrinksIDrecord component.- Returns:
- the value of the
createdDrinksIDrecord component
-
favoriteDrinkID
Returns the value of thefavoriteDrinkIDrecord component.- Returns:
- the value of the
favoriteDrinkIDrecord component
-