AVMLockingException now has I18N message for locked item error.

Added new variant of hasAccess() method to AVMLockingService to support the case where you already have the NodeRef of the webproject available (improves performance by removing the need to perform a lucene search to locate the webproject node).

git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@6017 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Kevin Roast
2007-06-19 13:45:12 +00:00
parent 04e4f0d286
commit 0d81c6a30d
5 changed files with 82 additions and 32 deletions

View File

@@ -28,6 +28,8 @@ package org.alfresco.service.cmr.avm.locking;
import java.io.Serializable;
import java.util.List;
import org.alfresco.service.cmr.repository.NodeRef;
/**
* Service to handle AVM locking.
* @author britt
@@ -123,6 +125,15 @@ public interface AVMLockingService
*/
public boolean hasAccess(String webProject, String avmPath, String user);
/**
* Is the user allowed to do anything to the given asset, other than read?
* @param webProjectRef The NodeRef to the web project that this path is being checked in.
* @param avmPath A full avmPath
* @param user The name of the user, group, role to check on.
* @return Whether the user has access.
*/
public boolean hasAccess(NodeRef webProjectRef, String avmPath, String user);
/**
* Get the names of all the web projects the service knows about.
* @return The list of web project names.