Record Class CurrentUserResponse
java.lang.Object
java.lang.Record
com.chaosguide.iam.vertex.client.dto.CurrentUserResponse
public record CurrentUserResponse(String id, String email, String username, String status, boolean emailVerified, CurrentUserResponse.AuthenticationContext authenticationContext, Map<String, com.fasterxml.jackson.databind.JsonNode> metadata)
extends Record
Safe GET /api/v1/auth/me view. Metadata is display data, never authorization.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final recordstatic final record -
Constructor Summary
ConstructorsConstructorDescriptionCurrentUserResponse(String id, String email, String username, String status, boolean emailVerified, CurrentUserResponse.AuthenticationContext authenticationContext, Map<String, com.fasterxml.jackson.databind.JsonNode> metadata) Creates an instance of aCurrentUserResponserecord class. -
Method Summary
Modifier and TypeMethodDescriptionReturns the value of theauthenticationContextrecord component.email()Returns the value of theemailrecord component.booleanReturns the value of theemailVerifiedrecord component.final booleanIndicates whether some other object is "equal to" this one.static CurrentUserResponsefromJson(com.fasterxml.jackson.databind.JsonNode root) Reject incomplete views rather than constructing an anonymous or default context.final inthashCode()Returns a hash code value for this object.id()Returns the value of theidrecord component.metadata()Returns the value of themetadatarecord component.status()Returns the value of thestatusrecord component.final StringtoString()Returns a string representation of this record class.username()Returns the value of theusernamerecord component.
-
Constructor Details
-
CurrentUserResponse
public CurrentUserResponse(String id, String email, String username, String status, boolean emailVerified, CurrentUserResponse.AuthenticationContext authenticationContext, Map<String, com.fasterxml.jackson.databind.JsonNode> metadata) Creates an instance of aCurrentUserResponserecord class.- Parameters:
id- the value for theidrecord componentemail- the value for theemailrecord componentusername- the value for theusernamerecord componentstatus- the value for thestatusrecord componentemailVerified- the value for theemailVerifiedrecord componentauthenticationContext- the value for theauthenticationContextrecord componentmetadata- the value for themetadatarecord component
-
-
Method Details
-
fromJson
Reject incomplete views rather than constructing an anonymous or default context. -
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. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with thecomparemethod from their corresponding wrapper classes. -
id
Returns the value of theidrecord component.- Returns:
- the value of the
idrecord component
-
email
Returns the value of theemailrecord component.- Returns:
- the value of the
emailrecord component
-
username
Returns the value of theusernamerecord component.- Returns:
- the value of the
usernamerecord component
-
status
Returns the value of thestatusrecord component.- Returns:
- the value of the
statusrecord component
-
emailVerified
public boolean emailVerified()Returns the value of theemailVerifiedrecord component.- Returns:
- the value of the
emailVerifiedrecord component
-
authenticationContext
Returns the value of theauthenticationContextrecord component.- Returns:
- the value of the
authenticationContextrecord component
-
metadata
-