|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.pow2.dao.AbstractDAO com.pow2.acl.dao.ACLDAO
Data access object for ACL.
Field Summary |
Fields inherited from class com.pow2.dao.AbstractDAO |
cat |
Constructor Summary | |
protected |
ACLDAO()
Default protected constructor. |
Method Summary | |
ArrayList |
getRolePermissions(Role role)
Get all the permissions for the input role. |
ArrayList |
getUserGroups(com.pow2.user.User user)
Get all the groups for the user. |
ArrayList |
getUserRoles(com.pow2.user.User user)
Get all the roles for the user. |
ArrayList |
getUserRoles(com.pow2.user.User user,
Group group)
Get all the roles for the user belonging to the input group. |
boolean |
hasUserPermission(com.pow2.user.User user,
Group group,
Permission permission)
Check if the user belonging to the input group has got the input permission. |
boolean |
hasUserPermission(com.pow2.user.User user,
Permission permission)
Check if the user has got the input permission. |
static ACLDAO |
instance()
Get the instance of DAO class. |
boolean |
isUserInGroup(com.pow2.user.User user,
Group group)
Check if the user belongs to the input group. |
boolean |
isUserInRole(com.pow2.user.User user,
Group group,
Role role)
Check if the user belonging to the input group has got the input role. |
boolean |
isUserInRole(com.pow2.user.User user,
Role role)
Check if the user has got the input role. |
Methods inherited from class com.pow2.dao.AbstractDAO |
assertion, closeResources, closeResources, closeResources, count, count, delete, delete, enableDebug, encode, getConnection, getConnection, getNewKey, isDebugEnabled, populate, setLike, setLike |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
protected ACLDAO()
Method Detail |
public static ACLDAO instance()
public boolean isUserInGroup(com.pow2.user.User user, Group group) throws Exception
user
- the user.group
- the group wich the user should belong to.
Exception
- if the query fails.public boolean isUserInRole(com.pow2.user.User user, Role role) throws Exception
user
- Description of the Parameterrole
- Description of the Parameter
Exception
- if the query fails.public boolean isUserInRole(com.pow2.user.User user, Group group, Role role) throws Exception
user
- the user.group
- the group wich the user belongs to.role
- the role that the user should have.
Exception
- if the query fails.public ArrayList getUserGroups(com.pow2.user.User user) throws Exception
user
- Description of the Parameter
Exception
- if the query fails.public ArrayList getUserRoles(com.pow2.user.User user) throws Exception
user
- Description of the Parameter
Exception
- if the query fails.public ArrayList getUserRoles(com.pow2.user.User user, Group group) throws Exception
user
- the user.group
- the group wich the user belongs to.
Exception
- if the query fails.public ArrayList getRolePermissions(Role role) throws Exception
role
- Description of the Parameter
Exception
- if the query fails.public boolean hasUserPermission(com.pow2.user.User user, Permission permission) throws Exception
user
- the user.permission
- Description of the Parameter
Exception
- if the query fails.public boolean hasUserPermission(com.pow2.user.User user, Group group, Permission permission) throws Exception
user
- the user.group
- the group wich the user belongs to.permission
- Description of the Parameter
Exception
- if the query fails.
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |