org.apache.jackrabbit.core.security.authorization
Interface WorkspaceAccessManager

All Known Implementing Classes:
SimpleWorkspaceAccessManager

public interface WorkspaceAccessManager

The WorkspaceAccessManager is responsible for workspace access. In contrast to Items that are identified, workspaces are named Objects on different class hierarchy.


Method Summary
 void close()
          Dispose this WorkspaceAccessManager and its resources.
 boolean grants(Set<Principal> principals, String workspaceName)
          Returns true if access to the workspace with the given name is granted to the to any of the specified principals.
 void init(Session systemSession)
          Initialize this WorkspaceAccessManager.
 

Method Detail

init

void init(Session systemSession)
          throws RepositoryException
Initialize this WorkspaceAccessManager.

Parameters:
systemSession - Session used to initialize this instance.
Throws:
RepositoryException - if an error occurs.

close

void close()
           throws RepositoryException
Dispose this WorkspaceAccessManager and its resources.

Throws:
RepositoryException - if an error occurs.

grants

boolean grants(Set<Principal> principals,
               String workspaceName)
               throws RepositoryException
Returns true if access to the workspace with the given name is granted to the to any of the specified principals.

Parameters:
principals - A set of principals to be tested for being allowed to access workspace identified by workspaceName.
workspaceName - Name of the workspace to be tested.
Returns:
true if the given set of principals is allowed to access the workspace with the specified name.
Throws:
RepositoryException - If an error occurs.


Copyright © 2004-2010 The Apache Software Foundation. All Rights Reserved.