public class WorkflowDescriptor extends AbstractDescriptor implements Validatable
Modifier and Type | Field and Description |
---|---|
protected Map |
commonActions |
protected List |
commonActionsList |
static String |
DOCTYPE_DECL |
protected List |
globalActions |
protected ConditionsDescriptor |
globalConditions |
protected List |
initialActions |
protected List |
joins |
protected Map |
metaAttributes |
protected List |
registers |
protected List |
splits |
protected List |
steps |
protected Map |
timerFunctions |
protected String |
workflowName |
static String |
XML_HEADER |
Constructor and Description |
---|
WorkflowDescriptor()
Deprecated.
use
DescriptorFactory instead |
WorkflowDescriptor(Element root)
Deprecated.
use
DescriptorFactory instead |
Modifier and Type | Method and Description |
---|---|
void |
addCommonAction(ActionDescriptor descriptor)
Add a common action
|
void |
addGlobalAction(ActionDescriptor descriptor)
Add a global action
|
void |
addInitialAction(ActionDescriptor descriptor)
Add an initial action
|
void |
addJoin(JoinDescriptor descriptor)
Add a join
|
void |
addSplit(SplitDescriptor descriptor)
Add a split
|
void |
addStep(StepDescriptor descriptor)
Add a step
|
ActionDescriptor |
getAction(int id) |
Map |
getCommonActions()
Get a Map of the common actions specified, keyed on actionId (an Integer)
|
List |
getGlobalActions()
Get a List of the global actions specified
|
ConditionsDescriptor |
getGlobalConditions() |
ActionDescriptor |
getInitialAction(int id) |
List |
getInitialActions()
Get a List of initial steps for this workflow
|
JoinDescriptor |
getJoin(int id) |
List |
getJoins()
Get a List of initial steps for this workflow
|
Map |
getMetaAttributes() |
String |
getName() |
List |
getRegisters() |
SplitDescriptor |
getSplit(int id) |
List |
getSplits()
Get a List of initial steps for this workflow
|
StepDescriptor |
getStep(int id) |
List |
getSteps()
Get a List of steps in this workflow
|
FunctionDescriptor |
getTriggerFunction(int id) |
Map |
getTriggerFunctions()
Get a Map of all trigger functions in this workflow
|
protected void |
init(Element root) |
boolean |
removeAction(ActionDescriptor actionToRemove)
Remove an action from this workflow completely.
|
void |
setName(String name) |
FunctionDescriptor |
setTriggerFunction(int id,
FunctionDescriptor descriptor)
Update a trigger function
|
void |
validate()
Validate this element, and propagate validation to all contained sub-elements.
|
void |
writeXML(PrintWriter out,
int indent) |
asXML, getEntityId, getId, getParent, hasId, setEntityId, setId, setParent
public static final String XML_HEADER
public static final String DOCTYPE_DECL
protected ConditionsDescriptor globalConditions
protected List commonActionsList
protected List globalActions
protected List initialActions
protected List joins
protected List registers
protected List splits
protected List steps
protected Map commonActions
protected Map metaAttributes
protected Map timerFunctions
protected String workflowName
public WorkflowDescriptor()
DescriptorFactory
insteadpublic WorkflowDescriptor(Element root)
DescriptorFactory
insteadpublic ActionDescriptor getAction(int id)
public Map getCommonActions()
ActionDescriptor
objectspublic List getGlobalActions()
ActionDescriptor
objectspublic ConditionsDescriptor getGlobalConditions()
public ActionDescriptor getInitialAction(int id)
public List getInitialActions()
ActionDescriptor
objectspublic JoinDescriptor getJoin(int id)
public List getJoins()
JoinDescriptor
objectspublic Map getMetaAttributes()
public void setName(String name)
public String getName()
public List getRegisters()
public SplitDescriptor getSplit(int id)
public List getSplits()
SplitDescriptor
objectspublic StepDescriptor getStep(int id)
public List getSteps()
StepDescriptor
objectspublic FunctionDescriptor setTriggerFunction(int id, FunctionDescriptor descriptor)
id
- The id for the trigger functiondescriptor
- The descriptor for the trigger functionpublic FunctionDescriptor getTriggerFunction(int id)
public Map getTriggerFunctions()
FunctionDescriptor
valuespublic void addCommonAction(ActionDescriptor descriptor)
descriptor
- The action descriptor to addIllegalArgumentException
- if the descriptor's ID already exists in the workflowpublic void addGlobalAction(ActionDescriptor descriptor)
descriptor
- The action descriptor to addIllegalArgumentException
- if the descriptor's ID already exists in the workflowpublic void addInitialAction(ActionDescriptor descriptor)
descriptor
- The action descriptor to addIllegalArgumentException
- if the descriptor's ID already exists in the workflowpublic void addJoin(JoinDescriptor descriptor)
descriptor
- The join descriptor to addIllegalArgumentException
- if the descriptor's ID already exists in the workflowpublic void addSplit(SplitDescriptor descriptor)
descriptor
- The split descriptor to addIllegalArgumentException
- if the descriptor's ID already exists in the workflowpublic void addStep(StepDescriptor descriptor)
descriptor
- The step descriptor to addIllegalArgumentException
- if the descriptor's ID already exists in the workflowpublic boolean removeAction(ActionDescriptor actionToRemove)
This method will check global actions and all steps.
public void validate() throws InvalidWorkflowDescriptorException
Validatable
validate
in interface Validatable
InvalidWorkflowDescriptorException
WorkflowLoader.load(java.io.InputStream)
public void writeXML(PrintWriter out, int indent)
protected void init(Element root)
Copyright © 2021 catworkx GmbH. All rights reserved.