Class WorkflowDefinitionExtensionPoint
- java.lang.Object
-
- org.ametys.runtime.plugin.component.AbstractLogEnabled
-
- org.ametys.runtime.plugin.component.AbstractThreadSafeComponentExtensionPoint<WorkflowDefinition>
-
- org.ametys.plugins.workflow.definition.WorkflowDefinitionExtensionPoint
-
- All Implemented Interfaces:
LogEnabled
,ExtensionPoint<WorkflowDefinition>
,Disposable
,Initializable
,Component
,Contextualizable
,Serviceable
,ThreadSafe
public class WorkflowDefinitionExtensionPoint extends AbstractThreadSafeComponentExtensionPoint<WorkflowDefinition>
TheWorkflowDefinition
extension point to list all available workflows.
-
-
Field Summary
Fields Modifier and Type Field Description protected Context
_cocoonContext
The Cocoon contextstatic String
ROLE
The Avalon role-
Fields inherited from class org.ametys.runtime.plugin.component.AbstractThreadSafeComponentExtensionPoint
_cocoonManager, _context, _manager
-
-
Constructor Summary
Constructors Constructor Description WorkflowDefinitionExtensionPoint()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected File
_getParamWorkflowDir()
Get the param workflows directory.protected String
_getWorkflowIdFromFilename(String filename)
Get the workflow ID from the workflow filename.void
addExtension(String id, String pluginName, String featureName, Configuration configuration)
Add an extension to this point.void
contextualize(Context context)
void
initializeExtensions()
Finalize the initialization of the extensions.
This method is called after alladdExtension()
calls.
This is the last step before the actual startup of the application.-
Methods inherited from class org.ametys.runtime.plugin.component.AbstractThreadSafeComponentExtensionPoint
addComponent, dispose, getExtension, getExtensionsIds, hasExtension, initialize, service
-
Methods inherited from class org.ametys.runtime.plugin.component.AbstractLogEnabled
getLogger, setLogger
-
-
-
-
Field Detail
-
_cocoonContext
protected Context _cocoonContext
The Cocoon context
-
-
Constructor Detail
-
WorkflowDefinitionExtensionPoint
public WorkflowDefinitionExtensionPoint()
-
-
Method Detail
-
contextualize
public void contextualize(Context context) throws ContextException
- Specified by:
contextualize
in interfaceContextualizable
- Overrides:
contextualize
in classAbstractThreadSafeComponentExtensionPoint<WorkflowDefinition>
- Throws:
ContextException
-
initializeExtensions
public void initializeExtensions() throws Exception
Description copied from interface:ExtensionPoint
Finalize the initialization of the extensions.
This method is called after alladdExtension()
calls.
This is the last step before the actual startup of the application.- Specified by:
initializeExtensions
in interfaceExtensionPoint<WorkflowDefinition>
- Overrides:
initializeExtensions
in classAbstractThreadSafeComponentExtensionPoint<WorkflowDefinition>
- Throws:
Exception
- if something wrong occurs
-
addExtension
public void addExtension(String id, String pluginName, String featureName, Configuration configuration) throws ConfigurationException
Description copied from interface:ExtensionPoint
Add an extension to this point. Each implementation knows the meaning of the given configuration.- Specified by:
addExtension
in interfaceExtensionPoint<WorkflowDefinition>
- Overrides:
addExtension
in classAbstractThreadSafeComponentExtensionPoint<WorkflowDefinition>
- Parameters:
id
- the unique identifier of the extension.pluginName
- Unique identifier for the plugin hosting the extensionfeatureName
- Unique feature identifier (unique for a given pluginName)configuration
- the information about the extension to be added- Throws:
ConfigurationException
- when a configuration problem occurs
-
_getParamWorkflowDir
protected File _getParamWorkflowDir()
Get the param workflows directory.- Returns:
- the workflows directory in WEB-INF/param.
-
_getWorkflowIdFromFilename
protected String _getWorkflowIdFromFilename(String filename)
Get the workflow ID from the workflow filename.- Parameters:
filename
- The workflow filename- Returns:
- the workflow ID
-
-