Class ExtensibleFunction
- java.lang.Object
-
- org.ametys.runtime.plugin.component.AbstractLogEnabled
-
- org.ametys.cms.workflow.extensions.ExtensibleFunction
-
- All Implemented Interfaces:
com.opensymphony.workflow.FunctionProvider
,LogEnabled
,Serviceable
public class ExtensibleFunction extends AbstractLogEnabled implements com.opensymphony.workflow.FunctionProvider, Serviceable
Workflow function that will call each function registered on the extension point given as an argument
-
-
Field Summary
Fields Modifier and Type Field Description protected ServiceManager
_manager
The service managerprotected static String
EXTENSION_POINT_ROLE_ARGS_KEY
The rights key.
-
Constructor Summary
Constructors Constructor Description ExtensibleFunction()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected com.opensymphony.workflow.FunctionProvider
_getFunctionProvider(String functionId, String functionProviderRole)
Get the function provider denotedprotected ExtensionPoint<String>
_getFunctionsExtensionPoint(Map args)
Get the function extension point given in argsvoid
execute(Map transientVars, Map args, com.opensymphony.module.propertyset.PropertySet ps)
void
service(ServiceManager manager)
-
Methods inherited from class org.ametys.runtime.plugin.component.AbstractLogEnabled
getLogger, setLogger
-
-
-
-
Field Detail
-
EXTENSION_POINT_ROLE_ARGS_KEY
protected static final String EXTENSION_POINT_ROLE_ARGS_KEY
The rights key.- See Also:
- Constant Field Values
-
_manager
protected ServiceManager _manager
The service manager
-
-
Constructor Detail
-
ExtensibleFunction
public ExtensibleFunction()
-
-
Method Detail
-
service
public void service(ServiceManager manager) throws ServiceException
- Specified by:
service
in interfaceServiceable
- Throws:
ServiceException
-
execute
public void execute(Map transientVars, Map args, com.opensymphony.module.propertyset.PropertySet ps) throws com.opensymphony.workflow.WorkflowException
- Specified by:
execute
in interfacecom.opensymphony.workflow.FunctionProvider
- Throws:
com.opensymphony.workflow.WorkflowException
-
_getFunctionProvider
protected com.opensymphony.workflow.FunctionProvider _getFunctionProvider(String functionId, String functionProviderRole) throws com.opensymphony.workflow.WorkflowException
Get the function provider denoted- Parameters:
functionId
- The id of the extension that gave the rolefunctionProviderRole
- The role of the component to find- Returns:
- The workflow function
- Throws:
com.opensymphony.workflow.WorkflowException
- If the role cannot be found
-
_getFunctionsExtensionPoint
protected ExtensionPoint<String> _getFunctionsExtensionPoint(Map args) throws com.opensymphony.workflow.WorkflowException
Get the function extension point given in args- Parameters:
args
- The workflow arguments- Returns:
- The extension point
- Throws:
com.opensymphony.workflow.WorkflowException
- If the extension point is not configured or does not exist
-
-