org.alfresco.web.app.servlet.command
Class BaseNodeCommandProcessor
java.lang.Object
org.alfresco.web.app.servlet.command.BaseNodeCommandProcessor
- All Implemented Interfaces:
- CommandProcessor
- Direct Known Subclasses:
- WorkflowCommandProcessor
public abstract class BaseNodeCommandProcessor
- extends java.lang.Object
- implements CommandProcessor
Initial implementation of a Command Processor that is always passed enough URL elements
to construct a single NodeRef argument. The NodeRef is checked against READ permissions
for the current user during the validateArguments() call.
This class should be enough to form the base of Command Processor objects that only require
a single NodeRef passed on the URL.
Field Summary |
protected org.alfresco.service.cmr.repository.NodeRef |
targetRef
|
Method Summary |
boolean |
validateArguments(javax.servlet.ServletContext sc,
java.lang.String command,
java.util.Map args,
java.lang.String[] urlElements)
Pass and validate URL arguments for the command processor. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
targetRef
protected org.alfresco.service.cmr.repository.NodeRef targetRef
BaseNodeCommandProcessor
public BaseNodeCommandProcessor()
validateArguments
public boolean validateArguments(javax.servlet.ServletContext sc,
java.lang.String command,
java.util.Map args,
java.lang.String[] urlElements)
- Description copied from interface:
CommandProcessor
- Pass and validate URL arguments for the command processor. Validate if the command can be
executed given the arguments supplied. Generally at this post a Command Processor will
convert the supplied arguments to the objects it expects, and also check any permissions
that are required by the current user to execute the command.
- Specified by:
validateArguments
in interface CommandProcessor
- Parameters:
sc
- ServletContext, can be used to retrieve ServiceRegistry instance
from the Repository bean.command
- Name of the command the arguments are forargs
- Map of URL args passed to the command servleturlElements
- String[] of the remaining URL arguments to the command servlet
- Returns:
- true if the command can be executed by the current user given the supplied args.
- See Also:
CommandProcessor.validateArguments(javax.servlet.ServletContext, java.lang.String, java.util.Map, java.lang.String[])
Copyright © 2005 - 2010 Alfresco Software, Inc. All Rights Reserved.