com.opensymphony.workflow.config
Interface Configuration

All Known Implementing Classes:
DefaultConfiguration, SpringConfiguration

public interface Configuration

Configuration object that is responsible for all 'static' workflow information. This includes loading of workflow configurations, setting up the workflow descriptor factory, as well as proxying calls to the underlying descriptor factory. Date: Mar 22, 2004 Time: 3:42:19 PM

Author:
hani

Method Summary
 String getPersistence()
          Get the fully qualified class name of the persistence store.
 Map getPersistenceArgs()
          Get the persistence args for the persistence store.
 VariableResolver getVariableResolver()
          Return the resolver to use for all variables specified in scripts
 WorkflowDescriptor getWorkflow(String name)
          Get the named workflow descriptor.
 String[] getWorkflowNames()
          Get a list of all available workflow descriptor names.
 WorkflowStore getWorkflowStore()
           
 boolean isInitialized()
           
 boolean isModifiable(String name)
          Check if a particular workflow can be modified or not.
 void load(URL url)
          Load the specified configuration file.
 boolean removeWorkflow(String workflow)
          Remove the specified workflow.
 boolean saveWorkflow(String name, WorkflowDescriptor descriptor, boolean replace)
           
 

Method Detail

isInitialized

boolean isInitialized()
Returns:
true if this factory has been initialised. If the factory is not initialised, then load(java.net.URL) will be called.

isModifiable

boolean isModifiable(String name)
Check if a particular workflow can be modified or not.

Parameters:
name - The workflow name.
Returns:
true if the workflow can be modified, false otherwise.

getPersistence

String getPersistence()
Get the fully qualified class name of the persistence store.


getPersistenceArgs

Map getPersistenceArgs()
Get the persistence args for the persistence store. Note that this returns the actual args and not a copy, so modifications to the returned Map could potentially affect store behaviour.


getVariableResolver

VariableResolver getVariableResolver()
Return the resolver to use for all variables specified in scripts


getWorkflow

WorkflowDescriptor getWorkflow(String name)
                               throws FactoryException
Get the named workflow descriptor.

Parameters:
name - the workflow name
Throws:
FactoryException - if there was an error looking up the descriptor or if it could not be found.

getWorkflowNames

String[] getWorkflowNames()
                          throws FactoryException
Get a list of all available workflow descriptor names.

Throws:
FactoryException - if the underlying factory does not support this method or if there was an error looking up workflow names.

getWorkflowStore

WorkflowStore getWorkflowStore()
                               throws StoreException
Throws:
StoreException

load

void load(URL url)
          throws FactoryException
Load the specified configuration file.

Parameters:
url - url to the configuration file.
Throws:
FactoryException

removeWorkflow

boolean removeWorkflow(String workflow)
                       throws FactoryException
Remove the specified workflow.

Parameters:
workflow - The workflow name of the workflow to remove.
Returns:
true if the workflow was removed, false otherwise.
Throws:
FactoryException - If the underlying workflow factory has an error removing the workflow, or if it does not support the removal of workflows.

saveWorkflow

boolean saveWorkflow(String name,
                     WorkflowDescriptor descriptor,
                     boolean replace)
                     throws FactoryException
Throws:
FactoryException

OpenSymphony Workflow Project Page