|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface CompiledPermissions
CompiledPermissions
represents the evaluation of an
AccessControlPolicy
that applies for a given set of
Principal
s (normally obtained from the Subject
of a Session).
Method Summary | |
---|---|
boolean |
canReadAll()
Returns true if READ permission is granted everywhere. |
void |
close()
Indicate to this CompiledPermissions object that it is
not used any more. |
int |
getPrivileges(Path absPath)
Returns the Privilege s granted by the underlying policy
if the given absPath denotes an existing Node ,
otherwise it returns zero. |
boolean |
grants(Path absPath,
int permissions)
Returns true if the specified permissions are granted
on the item identified by the given path . |
Method Detail |
---|
void close()
CompiledPermissions
object that it is
not used any more.
boolean grants(Path absPath, int permissions) throws RepositoryException
true
if the specified permissions are granted
on the item identified by the given path
.
absPath
- Absolute path pointing to an item. If the item does
not exist yet (asking for 'add-node' and 'set-property' permission),
it's direct ancestor must exist.permissions
- A combination of one or more of permission constants
defined by Permission
encoded as a bitmask value
true
if the specified permissions are granted,
false
otherwise.
RepositoryException
- if an error occurs.int getPrivileges(Path absPath) throws RepositoryException
Privilege
s granted by the underlying policy
if the given absPath
denotes an existing Node
,
otherwise it returns zero.
absPath
or zero if
the path does not denote an existing Node
.
RepositoryException
- if an error occursboolean canReadAll() throws RepositoryException
true
if READ permission is granted everywhere.
This method acts as shortcut for grants(Path, int)
where
permissions is Permission.READ
and allows to shorten the
evaluation time given the fact that a check for READ permission is
considered to be the most frequent test.
true
if the READ permission is granted everywhere.
RepositoryException
- if an error occurs
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |