Class User

  • All Implemented Interfaces:

    @Serializable() 
    public final class User
    
                        

    Represents the user model returned from mobile server.

    • Nested Class Summary

      Nested Classes 
      Modifier and Type Class Description
      public final class User.UserName
      public final class User.Email
    • Constructor Summary

      Constructors 
      Constructor Description
      User(String id, String userName, List<String> roles, User.UserName name, List<User.Email> emails, JsonElement detail)
    • Enum Constant Summary

      Enum Constants 
      Enum Constant Description
    • Method Summary

      Modifier and Type Method Description
      final String getId() The user id, mandatory.
      final String getUserName() The user name string, mandatory.
      final List<String> getRoles() The assigned roles of this user.
      final User.UserName getName() The UserName type user name property, which contains optional 'familyName' and 'givenName'.
      final List<User.Email> getEmails() The emails of this user.
      final JsonElement getDetail() The detail information, it could be either a JsonPrimitive, JsonObject or JsonArray.
      String toString()
      final static User createUserFromJsonString(String jsonString) Creates user instance from a json string
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • User

        User(String id, String userName, List<String> roles, User.UserName name, List<User.Email> emails, JsonElement detail)
    • Method Detail

      • getId

         final String getId()

        The user id, mandatory.

      • getUserName

         final String getUserName()

        The user name string, mandatory.

      • getRoles

         final List<String> getRoles()

        The assigned roles of this user.

      • getDetail

         final JsonElement getDetail()

        The detail information, it could be either a JsonPrimitive, JsonObject or JsonArray. It's up to the client code to parse this information.