com.flexive.shared.interfaces
Interface StepDefinitionEngine

All Known Subinterfaces:
StepDefinitionEngineLocal

public interface StepDefinitionEngine

Interface to the step definition engine.

Author:
Daniel Lichtenberger (daniel.lichtenberger@flexive.com), UCS - unique computing solutions gmbh (http://www.ucs.at)

Method Summary
 long create(StepDefinition stepDefinition)
          Creates a new step definition.
 void remove(long id)
          Removes a step definition.
 void update(StepDefinition stepDefinition)
          Modifies a existing StepDefinition.
 

Method Detail

create

long create(StepDefinition stepDefinition)
            throws FxApplicationException
Creates a new step definition.

The caller must be within ROLE_WORKFLOWMANAGEMENT.

Parameters:
stepDefinition - the step definition to be created
Returns:
The create step's ID
Throws:
FxApplicationException - TODO
FxCreateException - if the creation of the step definition failed
FxNoAccessException - if the caller lacks the permission to manage workflows
FxInvalidParameterException - if a parameter is invalid (empty name, invalid target ..)
FxEntryExistsException - If a step with the given name already exists

update

void update(StepDefinition stepDefinition)
            throws FxApplicationException
Modifies a existing StepDefinition.

The caller must be within ROLE_WORKFLOWMANAGEMENT.
If the modification adds/modifies a unique target all workflows are checked if a step with this definition exists, and if the new unqique target is defined. If the unqique target is missing in any workflow, it will be created using the ACL of the parent step.

Parameters:
stepDefinition - the stepdefinition to be stored
Throws:
FxApplicationException - TODO
FxNotFoundException - if the StepDefinition referenced by the parameter id does not exist
FxNoAccessException - if the caller lacks the permissions to modify the step
FxInvalidParameterException - if the uniqueTarget id is invalid
FxUpdateException - if the function failed to modify the step definition

remove

void remove(long id)
            throws FxApplicationException
Removes a step definition.

The caller must be within ROLE_WORKFLOWMANAGEMENT.

Parameters:
id - the unique id of the step definition to remove
Throws:
FxApplicationException - TODO
FxNotFoundException - if the step definition to remove does not exist
FxNoAccessException - if the caller lacks the permissions to remove the step definition
FxRemoveException - if the remove failed
FxEntryInUseException - if the step definition is used (needed) and cannot be removed