|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object info.magnolia.cms.security.RepositoryBackedSecurityManager info.magnolia.cms.security.MgnlRoleManager
public class MgnlRoleManager
Manages the users stored in the RepositoryConstants.USER_ROLES
workspace.
Field Summary | |
---|---|
static String |
NODE_ACLROLES
|
Constructor Summary | |
---|---|
MgnlRoleManager()
|
Method Summary | |
---|---|
void |
addPermission(Role role,
String workspace,
String path,
long permission)
Add permission to the specified role, assuming current user has enough rights to perform such operation. |
Role |
createRole(String name)
Creates a new role in the root folder without any security restrictions. |
Role |
createRole(String path,
String name)
Create a new role in a specific folder without any security restrictions. |
protected javax.jcr.Node |
findPrincipalNode(String principalName,
javax.jcr.Session session)
Helper method to find a role. |
protected HierarchyManager |
getHierarchyManager()
Deprecated. since 5.2 |
protected String |
getRepositoryName()
|
Role |
getRole(String name)
Get the specific role. |
String |
getRoleNameById(String string)
Retrieve role name by its identifier. |
protected MgnlRole |
newRoleInstance(Content node)
Deprecated. since 4.5 |
protected MgnlRole |
newRoleInstance(javax.jcr.Node node)
|
void |
removePermission(Role role,
String workspace,
String path,
long permission)
Remove permission from the specified role. |
protected void |
validateRoleName(String name)
|
Methods inherited from class info.magnolia.cms.security.RepositoryBackedSecurityManager |
---|
add, findPrincipalNode, findPrincipalNode, getACLs, getACLs, getResourceName, hasAny, remove |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface info.magnolia.cms.security.RoleManager |
---|
getACLs |
Field Detail |
---|
public static final String NODE_ACLROLES
Constructor Detail |
---|
public MgnlRoleManager()
Method Detail |
---|
public Role getRole(String name)
RoleManager
getRole
in interface RoleManager
public Role createRole(String name) throws AccessDeniedException
RoleManager
createRole
in interface RoleManager
AccessDeniedException
public Role createRole(String path, String name) throws AccessDeniedException
createRole
in interface RoleManager
IllegalArgumentException
- if the name is not valid or if a group with this name already exists
UnsupportedOperationException
- in case the role manager does not support this operation
AccessDeniedException
@Deprecated protected MgnlRole newRoleInstance(Content node) throws javax.jcr.RepositoryException
javax.jcr.RepositoryException
protected MgnlRole newRoleInstance(javax.jcr.Node node) throws javax.jcr.RepositoryException
javax.jcr.RepositoryException
@Deprecated protected HierarchyManager getHierarchyManager()
public void removePermission(Role role, String workspace, String path, long permission)
RoleManager
removePermission
in interface RoleManager
public void addPermission(Role role, String workspace, String path, long permission)
RoleManager
addPermission
in interface RoleManager
protected javax.jcr.Node findPrincipalNode(String principalName, javax.jcr.Session session) throws javax.jcr.RepositoryException
findPrincipalNode
in class RepositoryBackedSecurityManager
javax.jcr.RepositoryException
protected String getRepositoryName()
getRepositoryName
in class RepositoryBackedSecurityManager
public String getRoleNameById(String string)
RoleManager
getRoleNameById
in interface RoleManager
protected void validateRoleName(String name) throws AccessDeniedException
AccessDeniedException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |