Package org.dspace.xmlworkflow.state
Class Workflow
java.lang.Object
org.dspace.xmlworkflow.state.Workflow
- All Implemented Interfaces:
Aware,BeanNameAware
Contains all the steps involved in a certain configured workflow.
- Author:
- Bram De Schouwer (bram.deschouwer at dot com), Kevin Van de Velde (kevin at atmire dot com), Ben Bosman (ben at atmire dot com), Mark Diggory (markd at atmire dot com)
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiongetID()Get the name of this Workflow.getNextStep(Context context, XmlWorkflowItem wfi, Step currentStep, int outcome) Find the Step that follows a given Step given an outcome.getRoles()Get the roles that are used in this workflowReturn a step with a given name.getSteps()Get the steps that need to be executed in this workflow before the item is archivedvoidvoidsetFirstStep(Step firstStep) voidSet the steps that need to be executed in this workflow before the item is archived
-
Constructor Details
-
Workflow
public Workflow()
-
-
Method Details
-
getFirstStep
-
getID
Get the name of this Workflow.- Returns:
- the name.
- See Also:
-
getStep
Return a step with a given name.- Parameters:
stepID- name of the Step to find.- Returns:
- the identified Step.
- Throws:
WorkflowConfigurationException- if the named step is not found.
-
getNextStep
public Step getNextStep(Context context, XmlWorkflowItem wfi, Step currentStep, int outcome) throws WorkflowConfigurationException, SQLException Find the Step that follows a given Step given an outcome.- Parameters:
context-wfi- the item whose steps are consulted.currentStep- the step being consulted.outcome- the outcome ofcurrentStep.- Returns:
- the next step.
- Throws:
WorkflowConfigurationException- if the next step is invalid.SQLException- passed through.
-
setFirstStep
-
getSteps
Get the steps that need to be executed in this workflow before the item is archived- Returns:
- the workflow steps
-
setSteps
Set the steps that need to be executed in this workflow before the item is archived- Parameters:
steps- the workflow steps
-
getRoles
Get the roles that are used in this workflow- Returns:
- a map containing the roles, the role name will the key, the role itself the value
-
setBeanName
- Specified by:
setBeanNamein interfaceBeanNameAware
-