java.lang.Object
com.inductiveautomation.ignition.common.role.BasicRole
All Implemented Interfaces:
Role

public class BasicRole extends Object implements Role
A basic implementation of the Role interface.
  • Constructor Details

    • BasicRole

      public BasicRole(String profileName, String id)
      Construct a new BasicRole instance.
      Parameters:
      profileName - The name of user source profile this role is associated with.
      id - The role ID.
  • Method Details

    • getId

      public String getId()
      Description copied from interface: Role
      An opaque identifier that can be used to identify this role. Only valid (unique) within the context of the originating user profile
      Specified by:
      getId in interface Role
    • getName

      public String getName()
      Description copied from interface: Role
      The name of the role.
      Specified by:
      getName in interface Role
      Returns:
      The name of the role.
    • getNotes

      public String getNotes()
      Description copied from interface: Role
      The notes associated with the role.
      Specified by:
      getNotes in interface Role
      Returns:
      The notes associated with the role.
    • getProfileName

      public String getProfileName()
      Description copied from interface: Role
      The name of the user management profile this role was retrieved from.
      Specified by:
      getProfileName in interface Role
    • setName

      public void setName(String name)
      Set the role name.
      Parameters:
      name - The role name.
    • setNotes

      public void setNotes(String notes)
      Set the notes associated with this role.
      Parameters:
      notes - Notes about this role.
    • equals

      public boolean equals(Object obj)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • copy

      public static BasicRole copy(Role role)
      Copy a Role, which may or may not be a BasicRole, into a new BasicRole instance.
      Parameters:
      role - The role to copy.
      Returns:
      A new BasicRole with all known fields copied from the given role.