public interface RMRole
RMPrincipal
members for the custom Role
class.Modifier and Type | Method and Description |
---|---|
void |
addMember(RMPrincipal principal)
Adds given
RMPrincipal
to this RMRole . |
void |
delete()
Deletes this
RMRole from the repository. |
java.lang.String |
getApplicationName()
Returns the
ApplicationName property value. |
java.lang.String |
getDescription()
Returns the
Description property value. |
java.util.List<RMPrincipal> |
getMembers()
Returns the collection of
RMPrincipal
instances belonging to this RMRole . |
java.lang.String |
getObjectIdentity()
Provides a unique, repository-specific ID for the role.
|
java.lang.String |
getPrivileges()
Returns a
String version of the Privileges property value. |
java.lang.String |
getRoleName()
Returns the
RoleName property value. |
java.lang.String |
getRoleType()
Returns the
RoleType property value. |
boolean |
isCurrentUserInRole()
Indicates whether the current user is a member of this
RMRole . |
boolean |
isPrincipalInRole(RMPrincipal principal)
Indicates whether a specific principal is a member of this
RMRole . |
void |
removeMember(RMPrincipal principal)
Removes the specified
RMPrincipal
from this RMRole . |
void |
setDescription(java.lang.String description)
Defines an optional description.
|
void |
setPrivileges(java.lang.String privileges)
Sets the
Privileges property value. |
java.lang.String getObjectIdentity()
String
.String
value.java.lang.String getRoleName()
RoleName
property value.String
value.java.lang.String getApplicationName()
ApplicationName
property value.String
value.java.lang.String getRoleType()
RoleType
property value.String
value.java.lang.String getDescription()
Description
property value.String
value.void setDescription(java.lang.String description)
description
- a String
value.
This entry can be null
.RAL_INSUFFICIENT_RIGHTS_TO_ACCESS_ROLE
- if the current user does not have permission to access or update this role.RAL_RETRIEVING_SECURED_ACCESS_ROLE_FAILED
- if an unexpected retrieval error occurred.void addMember(RMPrincipal principal)
RMPrincipal
to this RMRole
. This entry has no effect if the given
principal is already in this role.principal
- the RMPrincipal
to add.
Cannot be null
.RAL_INSUFFICIENT_RIGHTS_TO_ACCESS_ROLE
- if the current user does not have permission to access or update this role.RAL_RETRIEVING_SECURED_ACCESS_ROLE_FAILED
- if an unexpected retrieval error occurred.void removeMember(RMPrincipal principal)
RMPrincipal
from this RMRole
. This entry has no effect if the given
principal is not a member of this role.principal
- the RMPrincipal
to remove.
Cannot be null
.RAL_INSUFFICIENT_RIGHTS_TO_ACCESS_ROLE
- if the current user does not have permission to access or update this role.RAL_RETRIEVING_SECURED_ACCESS_ROLE_FAILED
- if an unexpected retrieval error occurred.java.util.List<RMPrincipal> getMembers()
RMPrincipal
instances belonging to this RMRole
.List
of RMPrincipal
.
Can be empty.RAL_INSUFFICIENT_RIGHTS_TO_ACCESS_ROLE
- if the current user does not have permission to retrieve roles.RAL_RETRIEVING_SECURED_ACCESS_ROLE_FAILED
- if an unexpected retrieval error occurred.boolean isCurrentUserInRole()
RMRole
.
The current user is defined as the javax.security.auth.Subject
instance associated with the current thread.true
if the current user is a member of this role,
false
otherwise.RAL_RETRIEVING_SECURED_ACCESS_ROLE_FAILED
- if an unexpected retrieval error occurred.boolean isPrincipalInRole(RMPrincipal principal)
RMRole
.principal
- the RMPrincipal
to be checked against the role membership.true
if the principal is a member of this role,
false
otherwise.void delete()
RMRole
from the repository.RAL_INSUFFICIENT_RIGHTS_TO_ACCESS_ROLE
- if the current user does not have permission to retrieve or update roles.RAL_RETRIEVING_SECURED_ACCESS_ROLE_FAILED
- if an unexpected retrieval error occurred.java.lang.String getPrivileges()
String
version of the Privileges
property value.String
value.void setPrivileges(java.lang.String privileges)
Privileges
property value.privileges
- the String
version of the Privileges
property value.RAL_INSUFFICIENT_RIGHTS_TO_ACCESS_ROLE
- if the current user does not have permission to retrieve or update roles.RAL_RETRIEVING_SECURED_ACCESS_ROLE_FAILED
- if an unexpected retrieval error occurred.© Copyright IBM Corp. 2010, 2013. All Rights Reserved.