public interface AccessManagerPlugin
| Modifier and Type | Field and Description |
|---|---|
static int |
ADD_NODE |
static int |
ALL |
static int |
NONE |
static int |
READ |
static int |
REMOVE_NODE |
static int |
REMOVE_PROPERTY |
static int |
SET_PROPERTY |
| Modifier and Type | Method and Description |
|---|---|
boolean |
canRead(String itemPath)
Determines whether the item at the specified absolute path can be read.
|
void |
close()
Close this access manager.
|
WorkspaceAccessManagerPlugin |
getWorkspaceAccessManager()
Returns the
WorkspaceAccessManagerPlugin to be used for checking Workspace access. |
void |
init(Subject subject,
javax.jcr.Session session)
Initialize this access manager.
|
boolean |
isGranted(String absPath,
int permissions)
Determines whether the specified
permissions are granted
on the item with the specified absPath (i.e. |
static final int READ
static final int ADD_NODE
static final int REMOVE_NODE
static final int SET_PROPERTY
static final int REMOVE_PROPERTY
static final int ALL
static final int NONE
void init(Subject subject, javax.jcr.Session session) throws javax.jcr.AccessDeniedException, Exception
AccessDeniedException will
be thrown if the subject of the given context is not
granted access to the specified workspace.subject - The authenticated Subjectsession - The current JCR sessionjavax.jcr.AccessDeniedExceptionExceptionvoid close()
throws Exception
Exception - if an error occursboolean isGranted(String absPath, int permissions) throws javax.jcr.RepositoryException
permissions are granted
on the item with the specified absPath (i.e. the target
item, that may or may not yet exist).absPath - the absolute path to testpermissions - A combination of one or more of the following constants
encoded as a bitmask value:
READADD_NODEREMOVE_NODESET_PROPERTYREMOVE_PROPERTYtrue if the specified permissions are granted;
otherwise false.javax.jcr.RepositoryException - if an error occurs.boolean canRead(String itemPath) throws javax.jcr.RepositoryException
itemPath - Absolute path to the item being accessedtrue if the item can be read; otherwise false.javax.jcr.RepositoryException - if an error occurs.WorkspaceAccessManagerPlugin getWorkspaceAccessManager()
WorkspaceAccessManagerPlugin to be used for checking Workspace access.
If null is returned, the default WorkspaceAccessManager will be used.WorkspaceAccessManagerPlugin, or null to use
the default WorkspaceAccessManager.Copyright © 2014 The Apache Software Foundation. All rights reserved.