## imcode.server.user
Class RoleDomainObject

    java.lang.Object
      imcode.server.user.RoleDomainObject

All Implemented Interfaces:
  java.io.Serializable, java.lang.Comparable

    public class RoleDomainObject

extends java.lang.Object
implements java.io.Serializable, java.lang.Comparable

See Also:
  Serialized Form

Field Summary
`static RolePermissionDomainObject` `ADMIN_PAGES_PERMISSION`
`static RolePermissionDomainObject` `PASSWORD_MAIL_PERMISSION`

Constructor Summary
`RoleDomainObject(RoleId roleId, java.lang.String roleName, int adminRoleId)`
`RoleDomainObject(java.lang.String name)`

Method Summary
`void` `addPermission(RolePermissionDomainObject permission)`
`void` `addUnionOfPermissionIdsToRole(int unionOfRolePermissionIds)`
`int` `compareTo(java.lang.Object o)`
`boolean` `equals(java.lang.Object o)`
`static RolePermissionDomainObject[]` `getAllRolePermissions()`
`RoleId` `getId()`
`java.lang.String` `getName()`
`RolePermissionDomainObject[]` `getPermissions()`
`int` `hashCode()`
`boolean` `hasPermission(RolePermissionDomainObject permission)`
`boolean` `isAdminRole()`
`void` `removePermission(RolePermissionDomainObject permission)`
`void` `setId(RoleId id)`
`void` `setName(java.lang.String name)`
`java.lang.String` `toString()`

Methods inherited from class java.lang.Object
`clone, finalize, getClass, notify, notifyAll, wait, wait, wait`

Field Detail

### PASSWORD_MAIL_PERMISSION

    public static final RolePermissionDomainObject PASSWORD_MAIL_PERMISSION

### ADMIN_PAGES_PERMISSION

    public static final RolePermissionDomainObject ADMIN_PAGES_PERMISSION

Constructor Detail

### RoleDomainObject

    public RoleDomainObject(java.lang.String name)

### RoleDomainObject

    public RoleDomainObject(RoleId roleId,
                            java.lang.String roleName,
                            int adminRoleId)

Method Detail

### setId

    public void setId(RoleId id)

### getId

    public RoleId getId()

### getName

    public java.lang.String getName()

### setName

    public void setName(java.lang.String name)

### equals

    public boolean equals(java.lang.Object o)

  Overrides:
    `equals` in class `java.lang.Object`

### hashCode

    public int hashCode()

  Overrides:
    `hashCode` in class `java.lang.Object`

### toString

    public java.lang.String toString()

  Overrides:
    `toString` in class `java.lang.Object`

### isAdminRole

    public boolean isAdminRole()

### compareTo

    public int compareTo(java.lang.Object o)

  Specified by:
    `compareTo` in interface `java.lang.Comparable`

### addPermission

    public void addPermission(RolePermissionDomainObject permission)

### hasPermission

    public boolean hasPermission(RolePermissionDomainObject permission)

### removePermission

    public void removePermission(RolePermissionDomainObject permission)

### getPermissions

    public RolePermissionDomainObject[] getPermissions()

### addUnionOfPermissionIdsToRole

    public void addUnionOfPermissionIdsToRole(int unionOfRolePermissionIds)

### getAllRolePermissions

    public static RolePermissionDomainObject[] getAllRolePermissions()