Class Role


  • public class Role
    extends Object
    User role record.
    Author:
    Robert Fromont robert@fromont.net.nz
    • Constructor Detail

      • Role

        public Role()
        Default constructor.
      • Role

        public Role​(javax.json.JsonObject json)
        Constructor from JSON.
        Parameters:
        json - A JSON representation of the object to construct.
    • Method Detail

      • getRoleId

        public String getRoleId()
        Getter for roleId: Role name/ID.
        Returns:
        Role name/ID.
      • setRoleId

        public Role setRoleId​(String newRoleId)
        Setter for roleId: Role name/ID.
        Parameters:
        newRoleId - Role name/ID.
        Returns:
        A reference to this object, so that setters can be chained.
      • getDescription

        public String getDescription()
        Getter for description: Description of the role.
        Returns:
        Description of the role.
      • setDescription

        public Role setDescription​(String newDescription)
        Setter for description: Description of the role.
        Parameters:
        newDescription - Description of the role.
        Returns:
        A reference to this object, so that setters can be chained.
      • toJson

        public javax.json.JsonObject toJson()
        Serializes the object to JSON.
        Returns:
        A JSON serialization of the object.