Record Class LoginResponse
java.lang.Object
java.lang.Record
fr.tiogars.domaintemplate.domains.auth.models.LoginResponse
-
Constructor Summary
ConstructorsConstructorDescriptionLoginResponse(@NotNull String token, @NotNull String tokenType, @NotNull Instant expiresAt, @NotNull User user) Creates an instance of aLoginResponserecord class. -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.@NotNull InstantReturns the value of theexpiresAtrecord component.final inthashCode()Returns a hash code value for this object.@NotNull Stringtoken()Returns the value of thetokenrecord component.@NotNull StringReturns the value of thetokenTyperecord component.final StringtoString()Returns a string representation of this record class.@NotNull Useruser()Returns the value of theuserrecord component.
-
Constructor Details
-
LoginResponse
public LoginResponse(@NotNull @NotNull String token, @NotNull @NotNull String tokenType, @NotNull @NotNull Instant expiresAt, @NotNull @NotNull User user) Creates an instance of aLoginResponserecord class.- Parameters:
token- the value for thetokenrecord componenttokenType- the value for thetokenTyperecord componentexpiresAt- the value for theexpiresAtrecord componentuser- the value for theuserrecord component
-
-
Method Details
-
toString
-
hashCode
-
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). -
token
Returns the value of thetokenrecord component.- Returns:
- the value of the
tokenrecord component
-
tokenType
Returns the value of thetokenTyperecord component.- Returns:
- the value of the
tokenTyperecord component
-
expiresAt
Returns the value of theexpiresAtrecord component.- Returns:
- the value of the
expiresAtrecord component
-
user
Returns the value of theuserrecord component.- Returns:
- the value of the
userrecord component
-