it.eng.spago.workflow.api
Interface IWorkflowEngine


public interface IWorkflowEngine

Author:
zoppello This is the core interface of SpagoWorkflowAPI that represent a Worflow Engine In Spago Worflow API The workflow Engine is responsible for

Method Summary
 java.util.List getAvailablePackages()
          This method retrieve the List of the packages that can be loaded in the engine but that are not loaded in the engine
 java.util.List getLoadedPackges()
          This method retrieve the List of the packages that are loaded in the engine
 java.lang.String getPackagePathById(java.lang.String pkgId)
          Return the package phisical path given the path id
 IWorkflowConnection getWorkflowConnection()
          This method get a connection to the engine
 IWorkflowPackage getWorkflowPackage(java.lang.String pkgId)
          This method return an instance of IWorkflowPackage given a package id
 IWorkflowPackage loadPackageDefinition(java.lang.String pkgDefinitionFileName)
          This method load a packege containing Workflow Definitions in the engine
 void unloadPackageDefinition(IWorkflowPackage pkg)
          This method cause the unload of the IWorkflow package by the engine After this operation we cannot use anymore the IWorkflowPackage until a loadPackage Occurs
 

Method Detail

getWorkflowConnection

IWorkflowConnection getWorkflowConnection()
                                          throws WorkflowEngineException
This method get a connection to the engine

Returns:
a IWorkflowConnection object to make operation on the engine
Throws:
WorkflowEngineException - if some error occurs getting connection by the engine

loadPackageDefinition

IWorkflowPackage loadPackageDefinition(java.lang.String pkgDefinitionFileName)
                                       throws WorkflowEngineException
This method load a packege containing Workflow Definitions in the engine

Parameters:
pkgDefinitionFileName - The file containing the package definition
Returns:
a IWorkflowPackage a IWorkflow Package object representig the package loaded in the engine
Throws:
WorkflowEngineException - if some error occurs during the loading of the packege in the engine

unloadPackageDefinition

void unloadPackageDefinition(IWorkflowPackage pkg)
                             throws WorkflowEngineException
This method cause the unload of the IWorkflow package by the engine After this operation we cannot use anymore the IWorkflowPackage until a loadPackage Occurs

Parameters:
pkg - IWorkflowPackage that must be unloaded by the engine
Throws:
WorkflowEngineException

getLoadedPackges

java.util.List getLoadedPackges()
                                throws WorkflowEngineException
This method retrieve the List of the packages that are loaded in the engine

Returns:
the list of IWorkflowPackage object loaded in the engine
Throws:
WorkflowEngineException

getAvailablePackages

java.util.List getAvailablePackages()
                                    throws WorkflowEngineException
This method retrieve the List of the packages that can be loaded in the engine but that are not loaded in the engine

Returns:
the list of the packages available but that are not laoded in the engine
Throws:
WorkflowEngineException

getWorkflowPackage

IWorkflowPackage getWorkflowPackage(java.lang.String pkgId)
                                    throws WorkflowEngineException
This method return an instance of IWorkflowPackage given a package id

Parameters:
pkgId - The id of the package to retrieve
Returns:
The IWorkflow package instance
Throws:
WorkflowEngineException - if some error occurs getting a package

getPackagePathById

java.lang.String getPackagePathById(java.lang.String pkgId)
                                    throws WorkflowEngineException
Return the package phisical path given the path id

Parameters:
pkgId - The package Identifier for wivh we want to retrieve the path
Returns:
hisical path given the path id
Throws:
WorkflowEngineException - if some errors occurs