public interface RoleManagerLocal
| Modifier and Type | Method and Description |
|---|---|
void |
addResourceGroupsToRole(org.rhq.core.domain.auth.Subject subject,
int roleId,
int[] pendingGroupIds)
Adds the given resource groups to the given role.
|
void |
addRolesToResourceGroup(org.rhq.core.domain.auth.Subject subject,
int groupId,
int[] roleIds) |
void |
addRolesToSubject(org.rhq.core.domain.auth.Subject subject,
int subjectId,
int[] roleIds)
Assigns a set of roles to a subject which authorizes the subject to do anything the roles permit.
|
void |
addSubjectsToRole(org.rhq.core.domain.auth.Subject subject,
int roleId,
int[] subjectIds) |
org.rhq.core.domain.authz.Role |
createRole(org.rhq.core.domain.auth.Subject subject,
org.rhq.core.domain.authz.Role newRole)
Persists the new role to the database.
|
void |
deleteRoles(org.rhq.core.domain.auth.Subject subject,
int[] doomedRoleIds)
Removes a set of roles from the database.
|
org.rhq.core.domain.util.PageList<org.rhq.core.domain.authz.Role> |
findAvailableRolesForSubject(org.rhq.core.domain.auth.Subject subject,
Integer subjectId,
Integer[] pendingRoleIds,
org.rhq.core.domain.util.PageControl pc)
This returns a list of roles that are available to be assigned to a given subject but not yet assigned to that
subject.
|
org.rhq.core.domain.util.PageList<org.rhq.core.domain.authz.Role> |
findRoles(org.rhq.core.domain.util.PageControl pc)
Returns a list of all roles in the system.
|
org.rhq.core.domain.util.PageList<org.rhq.core.domain.authz.Role> |
findRolesByCriteria(org.rhq.core.domain.auth.Subject subject,
org.rhq.core.domain.criteria.RoleCriteria criteria) |
org.rhq.core.domain.util.PageList<org.rhq.core.domain.authz.Role> |
findRolesByIds(Integer[] roleIds,
org.rhq.core.domain.util.PageControl pc)
Given a set of role Ids, this returns a list of all the roles.
|
org.rhq.core.domain.util.PageList<org.rhq.core.domain.authz.Role> |
findRolesBySubject(int subjectId,
org.rhq.core.domain.util.PageControl pc)
This returns a page list of all the roles that a subject is authorized to access.
|
org.rhq.core.domain.util.PageList<org.rhq.core.domain.authz.Role> |
findSubjectAssignedRoles(org.rhq.core.domain.auth.Subject subject,
int subjectId,
org.rhq.core.domain.util.PageControl pc) |
org.rhq.core.domain.util.PageList<org.rhq.core.domain.auth.Subject> |
findSubjectsByRole(Integer roleId,
org.rhq.core.domain.util.PageControl pc)
Get all subjects that have been assigned the given role.
|
org.rhq.core.domain.util.PageList<org.rhq.core.domain.authz.Role> |
findSubjectUnassignedRoles(org.rhq.core.domain.auth.Subject subject,
int subjectId,
org.rhq.core.domain.util.PageControl pc) |
Set<org.rhq.core.domain.authz.Permission> |
getPermissions(Integer roleId)
Given a role ID, this will return the complete set of authorized permissions for that role.
|
org.rhq.core.domain.authz.Role |
getRole(org.rhq.core.domain.auth.Subject subject,
int roleId) |
org.rhq.core.domain.authz.Role |
getRoleById(Integer roleId)
Deprecated.
|
void |
removeResourceGroupsFromRole(org.rhq.core.domain.auth.Subject subject,
int roleId,
int[] groupIds)
Removes the given resource groups from the given role.
|
void |
removeRolesFromResourceGroup(org.rhq.core.domain.auth.Subject subject,
int groupId,
int[] roleIds) |
void |
removeRolesFromSubject(org.rhq.core.domain.auth.Subject subject,
int subjectId,
int[] roleIds)
Disassociates particular roles from a subject.
|
void |
removeSubjectsFromRole(org.rhq.core.domain.auth.Subject subject,
int roleId,
int[] subjectIds) |
void |
setAssignedResourceGroups(org.rhq.core.domain.auth.Subject subject,
int roleId,
int[] groupIds) |
void |
setAssignedSubjectRoles(org.rhq.core.domain.auth.Subject subject,
int subjectId,
int[] roleIds) |
void |
setAssignedSubjects(org.rhq.core.domain.auth.Subject sessionSubject,
int roleId,
int[] subjectIds) |
void |
setPermissions(org.rhq.core.domain.auth.Subject subject,
Integer roleId,
Set<org.rhq.core.domain.authz.Permission> permissions)
Sets the permissions for the specified role.
|
org.rhq.core.domain.authz.Role |
updateRole(org.rhq.core.domain.auth.Subject subject,
org.rhq.core.domain.authz.Role role)
Updates the given role, excluding the subjects and groups.
|
org.rhq.core.domain.util.PageList<org.rhq.core.domain.authz.Role> findRolesBySubject(int subjectId,
org.rhq.core.domain.util.PageControl pc)
subjectId - the id of the subject whose roles are to be returnedpc - org.rhq.core.domain.util.PageList<org.rhq.core.domain.authz.Role> findRoles(org.rhq.core.domain.util.PageControl pc)
pc - org.rhq.core.domain.authz.Role createRole(org.rhq.core.domain.auth.Subject subject,
org.rhq.core.domain.authz.Role newRole)
subject - the user attempting to create the rolenewRole - the new role to persistvoid deleteRoles(org.rhq.core.domain.auth.Subject subject,
int[] doomedRoleIds)
subject - the user attempting to delete the roledoomedRoleIds - the IDs of the roles to deletevoid setPermissions(org.rhq.core.domain.auth.Subject subject,
Integer roleId,
Set<org.rhq.core.domain.authz.Permission> permissions)
permissions will be the complete set of permissions the role will now be authorized with.subject - the user attempting to peform the setroleId - the ID of the role to modifypermissions - a set of permissions to give to the roleSet<org.rhq.core.domain.authz.Permission> getPermissions(Integer roleId)
roleId - org.rhq.core.domain.authz.Role updateRole(org.rhq.core.domain.auth.Subject subject,
org.rhq.core.domain.authz.Role role)
subject - user asking to update the rolerole - org.rhq.core.domain.util.PageList<org.rhq.core.domain.authz.Role> findRolesByIds(Integer[] roleIds, org.rhq.core.domain.util.PageControl pc)
roleIds - pc - org.rhq.core.domain.util.PageList<org.rhq.core.domain.auth.Subject> findSubjectsByRole(Integer roleId, org.rhq.core.domain.util.PageControl pc)
roleId - pc - org.rhq.core.domain.util.PageList<org.rhq.core.domain.authz.Role> findAvailableRolesForSubject(org.rhq.core.domain.auth.Subject subject,
Integer subjectId,
Integer[] pendingRoleIds,
org.rhq.core.domain.util.PageControl pc)
pendingRoleIds since it is assumed the pending roles will be assigned to the user.subject - user attempting to make this callsubjectId - the subject whose list of available roles are to be returnedpendingRoleIds - the list of roles that are planned to be given to the subjectpc - @Deprecated org.rhq.core.domain.authz.Role getRoleById(Integer roleId)
roleId - null if it wasn't foundorg.rhq.core.domain.authz.Role getRole(org.rhq.core.domain.auth.Subject subject,
int roleId)
org.rhq.core.domain.util.PageList<org.rhq.core.domain.authz.Role> findSubjectAssignedRoles(org.rhq.core.domain.auth.Subject subject,
int subjectId,
org.rhq.core.domain.util.PageControl pc)
org.rhq.core.domain.util.PageList<org.rhq.core.domain.authz.Role> findSubjectUnassignedRoles(org.rhq.core.domain.auth.Subject subject,
int subjectId,
org.rhq.core.domain.util.PageControl pc)
void addRolesToSubject(org.rhq.core.domain.auth.Subject subject,
int subjectId,
int[] roleIds)
subject - the user attempting to assign the roles to the subjectsubjectId - the subject who is to be authorized with the given rolesroleIds - the roles to assignvoid removeRolesFromSubject(org.rhq.core.domain.auth.Subject subject,
int subjectId,
int[] roleIds)
subject - the user that is attempting to perform the removesubjectId - the user that is to have the roles unassigned from itroleIds - list of role IDs that are to be removed from uservoid setAssignedSubjectRoles(org.rhq.core.domain.auth.Subject subject,
int subjectId,
int[] roleIds)
void addSubjectsToRole(org.rhq.core.domain.auth.Subject subject,
int roleId,
int[] subjectIds)
void removeSubjectsFromRole(org.rhq.core.domain.auth.Subject subject,
int roleId,
int[] subjectIds)
void setAssignedSubjects(org.rhq.core.domain.auth.Subject sessionSubject,
int roleId,
int[] subjectIds)
void addResourceGroupsToRole(org.rhq.core.domain.auth.Subject subject,
int roleId,
int[] pendingGroupIds)
subject - user attempting to add the groups to the roleroleId - pendingGroupIds - void addRolesToResourceGroup(org.rhq.core.domain.auth.Subject subject,
int groupId,
int[] roleIds)
void setAssignedResourceGroups(org.rhq.core.domain.auth.Subject subject,
int roleId,
int[] groupIds)
void removeResourceGroupsFromRole(org.rhq.core.domain.auth.Subject subject,
int roleId,
int[] groupIds)
subject - user attempting to remove the groups from the roleroleId - groupIds - void removeRolesFromResourceGroup(org.rhq.core.domain.auth.Subject subject,
int groupId,
int[] roleIds)
org.rhq.core.domain.util.PageList<org.rhq.core.domain.authz.Role> findRolesByCriteria(org.rhq.core.domain.auth.Subject subject,
org.rhq.core.domain.criteria.RoleCriteria criteria)
Copyright © 2008-2013 Red Hat, Inc.. All Rights Reserved.