|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.springframework.orm.ojb.support.PersistenceBrokerDaoSupport
org.apache.jetspeed.security.impl.PermissionManagerImpl
Implementation for managing Permission
and permission association to
Principal
. Permissions are used to manage Principals access
entitlement on specified resources.
For instance:
grant principal o.a.j.security.UserPrincipal "theUserPrincipal" { permission o.a.j.security.PortletPermission "myportlet", "view,edit,minimize,maximize"; };
<pre>
Field Summary | |
private static org.apache.commons.logging.Log |
log
|
Fields inherited from class org.springframework.orm.ojb.support.PersistenceBrokerDaoSupport |
logger |
Constructor Summary | |
PermissionManagerImpl()
|
Method Summary | |
void |
addPermission(Permission permission)
|
private Permissions |
appendSecurityPermissions(Collection omPermissions,
Permissions permissions)
Iterate through a collection of InternalPermission and build a
unique collection of Permission . |
(package private) org.apache.jetspeed.security.om.InternalPermission |
getInternalPermission(Permission permission)
Returns the InternalPermission from a Permission. |
(package private) org.apache.jetspeed.security.om.InternalPrincipal |
getInternalPrincipal(String fullPath)
Returns the InternalPrincipal from the full path. |
Permissions |
getPermissions(Collection principals)
|
Permissions |
getPermissions(Principal principal)
|
private Collection |
getPrincipalsFullPath(Collection principals)
Get the full path for the Principal in the collection. |
void |
grantPermission(Principal principal,
Permission permission)
|
boolean |
permissionExists(Permission permission)
|
void |
removePermission(Permission permission)
|
void |
removePermissions(Principal principal)
|
void |
revokePermission(Principal principal,
Permission permission)
|
Methods inherited from class org.springframework.orm.ojb.support.PersistenceBrokerDaoSupport |
afterPropertiesSet, closePersistenceBrokerIfNecessary, convertOjbAccessException, createPersistenceBrokerTemplate, getJcdAlias, getPersistenceBroker, getPersistenceBrokerTemplate, initDao, setJcdAlias, setPersistenceBrokerTemplate |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
private static final org.apache.commons.logging.Log log
Constructor Detail |
public PermissionManagerImpl()
Method Detail |
public Permissions getPermissions(Principal principal)
getPermissions
in interface org.apache.jetspeed.security.PermissionManager
PermissionManager.getPermissions(java.security.Principal)
public Permissions getPermissions(Collection principals)
getPermissions
in interface org.apache.jetspeed.security.PermissionManager
PermissionManager.getPermissions(java.util.Collection)
private Collection getPrincipalsFullPath(Collection principals)
Get the full path for the Principal
in the collection.
principals
- The collection of principals.
private Permissions appendSecurityPermissions(Collection omPermissions, Permissions permissions)
Iterate through a collection of InternalPermission
and build a
unique collection of Permission
.
omPermissions
- The collection of InternalPermission
.
Permission
.public void addPermission(Permission permission) throws org.apache.jetspeed.security.SecurityException
addPermission
in interface org.apache.jetspeed.security.PermissionManager
org.apache.jetspeed.security.SecurityException
PermissionManager.addPermission(java.security.Permission)
public void removePermission(Permission permission) throws org.apache.jetspeed.security.SecurityException
removePermission
in interface org.apache.jetspeed.security.PermissionManager
org.apache.jetspeed.security.SecurityException
PermissionManager.removePermission(java.security.Permission)
public void removePermissions(Principal principal) throws org.apache.jetspeed.security.SecurityException
removePermissions
in interface org.apache.jetspeed.security.PermissionManager
org.apache.jetspeed.security.SecurityException
PermissionManager.removePermissions(java.security.Principal)
public void grantPermission(Principal principal, Permission permission) throws org.apache.jetspeed.security.SecurityException
grantPermission
in interface org.apache.jetspeed.security.PermissionManager
org.apache.jetspeed.security.SecurityException
PermissionManager.grantPermission(java.security.Principal,
java.security.Permission)
public boolean permissionExists(Permission permission)
permissionExists
in interface org.apache.jetspeed.security.PermissionManager
PermissionManager.permissionExists(java.security.Permission)
public void revokePermission(Principal principal, Permission permission) throws org.apache.jetspeed.security.SecurityException
revokePermission
in interface org.apache.jetspeed.security.PermissionManager
org.apache.jetspeed.security.SecurityException
PermissionManager.revokePermission(java.security.Principal,
java.security.Permission)
org.apache.jetspeed.security.om.InternalPrincipal getInternalPrincipal(String fullPath)
Returns the InternalPrincipal
from the full path.
fullPath
- The full path.
InternalPrincipal
.org.apache.jetspeed.security.om.InternalPermission getInternalPermission(Permission permission)
Returns the InternalPermission
from a Permission.
permission
- The permission.
InternalPermission
.
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |