Class DomainRoleEntry

  • All Implemented Interfaces:
    JoynrType, Serializable

    public class DomainRoleEntry
    extends Object
    implements Serializable, JoynrType
    The Domain Role Entry (DRE) stores domains for users/role combination. User may become specified role when accessing given domains ACEs/RCEs in ACL/RCL. DREs are stored in the Domain Roles Table (DRT) using the pair (uid, role) as combined primary key.
    See Also:
    Serialized Form
    • Constructor Detail

      • DomainRoleEntry

        public DomainRoleEntry()
        Default Constructor
      • DomainRoleEntry

        public DomainRoleEntry​(DomainRoleEntry domainRoleEntryObj)
        Copy constructor
        Parameters:
        domainRoleEntryObj - reference to the object to be copied
      • DomainRoleEntry

        public DomainRoleEntry​(String uid,
                               String[] domains,
                               Role role)
        Parameterized constructor
        Parameters:
        uid - The unique user ID (UID) this entry applies to.
        domains - A list of domains this entry applies to. A domain might also contain the wildcard character (asterisk sign) to refer to all (sub-) domains.
        role - The role that is assigned to the specified user for the specified domains.
    • Method Detail

      • getUid

        public String getUid()
        Gets Uid
        Returns:
        The unique user ID (UID) this entry applies to.
      • setUid

        public void setUid​(String uid)
        Sets Uid
        Parameters:
        uid - The unique user ID (UID) this entry applies to.
      • getDomains

        public String[] getDomains()
        Gets Domains
        Returns:
        A list of domains this entry applies to. A domain might also contain the wildcard character (asterisk sign) to refer to all (sub-) domains.
      • setDomains

        public void setDomains​(String[] domains)
        Sets Domains
        Parameters:
        domains - A list of domains this entry applies to. A domain might also contain the wildcard character (asterisk sign) to refer to all (sub-) domains.
      • getRole

        public Role getRole()
        Gets Role
        Returns:
        The role that is assigned to the specified user for the specified domains.
      • setRole

        public void setRole​(Role role)
        Sets Role
        Parameters:
        role - The role that is assigned to the specified user for the specified domains.
      • toString

        public String toString()
        Stringifies the class
        Overrides:
        toString in class Object
        Returns:
        stringified class content
      • equals

        public boolean equals​(Object obj)
        Check for equality
        Overrides:
        equals in class Object
        Parameters:
        obj - Reference to the object to compare to
        Returns:
        true, if objects are equal, false otherwise
      • hashCode

        public int hashCode()
        Calculate code for hashing based on member contents
        Overrides:
        hashCode in class Object
        Returns:
        The calculated hash code