Class AbstractUserRepresentation

java.lang.Object
org.keycloak.representations.idm.AbstractUserRepresentation
Direct Known Subclasses:
UserRepresentation, UserRepresentation

public abstract class AbstractUserRepresentation extends Object
  • Field Details

    • USERNAME

      public static String USERNAME
    • FIRST_NAME

      public static String FIRST_NAME
    • LAST_NAME

      public static String LAST_NAME
    • EMAIL

      public static String EMAIL
    • LOCALE

      public static String LOCALE
    • id

      protected String id
    • username

      protected String username
    • firstName

      protected String firstName
    • lastName

      protected String lastName
    • email

      protected String email
    • emailVerified

      protected Boolean emailVerified
    • attributes

      protected Map<String,List<String>> attributes
  • Constructor Details

    • AbstractUserRepresentation

      public AbstractUserRepresentation()
  • Method Details

    • getId

      public String getId()
    • setId

      public void setId(String id)
    • getFirstName

      public String getFirstName()
    • setFirstName

      public void setFirstName(String firstName)
    • getLastName

      public String getLastName()
    • setLastName

      public void setLastName(String lastName)
    • getEmail

      public String getEmail()
    • setEmail

      public void setEmail(String email)
    • isEmailVerified

      public Boolean isEmailVerified()
    • setEmailVerified

      public void setEmailVerified(Boolean emailVerified)
    • getUsername

      public String getUsername()
    • setUsername

      public void setUsername(String username)
    • getAttributes

      public Map<String,List<String>> getAttributes()
      Returns all the attributes set to this user except the root attributes.
      Returns:
      the user attributes.
    • getRawAttributes

      public Map<String,List<String>> getRawAttributes()
      Returns all the user attributes including the root attributes.
      Returns:
      all the user attributes.
    • setAttributes

      public void setAttributes(Map<String,List<String>> attributes)
    • singleAttribute

      public <R extends AbstractUserRepresentation> R singleAttribute(String name, String value)
    • firstAttribute

      public String firstAttribute(String key)
    • setUserProfileMetadata

      public void setUserProfileMetadata(UserProfileMetadata userProfileMetadata)
    • getUserProfileMetadata

      public UserProfileMetadata getUserProfileMetadata()