Class FlowGraphEndPoint.Throwing
- java.lang.Object
-
- de.xima.fc.mdl.workflow.FlowGraphEndPoint
-
- de.xima.fc.mdl.workflow.FlowGraphEndPoint.Throwing
-
- All Implemented Interfaces:
INodeKeyProviding
,Serializable
- Enclosing class:
- FlowGraphEndPoint
public static final class FlowGraphEndPoint.Throwing extends FlowGraphEndPoint
A special type ofFlowGraphEndPoint
, used when analyzing the control flow of a workflow processing chain.A throwing end point is a node that can
INodeExecutionParams
complete abruptly
bythrowing an exception
and does not always transfer control to the node or a child of the node when it completes abruptly by throwing an exception. For example, most business logic actions can throw exceptions, in additional to also being able to complete normally. Special actions such as the throw statement always complete abruptly by throwing an exception.More formally, given a syntax tree of nodes representing the parent-child relationship, the throwing end points of a node n are the set of all nodes {m} such that all of the following hold:
- (a) m is in the subtree of n,
- (b) m can potentially (but might not always) complete abruptly by throwing an exception; and
- (c) m does not always transfer control to a node in the subtree of n when m completes abruptly by throwing an exception.
The subtree of a node n is set of all nodes {m} that are either equal to n or have n as one of their parents.
Condition (a) follows from the hierarchical execution principle of the workflow engine. A node, when asked to execute, may choose to execute some of its children in its subtree depending on the circumstances (such as an if-else statement that execute one of its two children depending on the outcome of a condition); but may never execute any other nodes outside its subtree. This implies that nodes can never transfer control to any node outside its subtree.
Condition (b) allows for other types of completion. A node is allowed to complete in other manners depending on the circumstances, such as a business logic action that usually completes normally unless there is an error.
Condition (c) is required for cases such as a try-catch statements, where no node within the try block can be a throwing end point with respect to the try-catch statement, as control is always transferred to the catch block when a node within the try block completes abruptly by throwing an exception.
- Since:
- 8.2.0
- See Also:
- Serialized Form
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class de.xima.fc.mdl.workflow.FlowGraphEndPoint
FlowGraphEndPoint.ControlTransfer, FlowGraphEndPoint.Normal, FlowGraphEndPoint.Returning, FlowGraphEndPoint.Throwing
-
-
Field Summary
-
Fields inherited from class de.xima.fc.mdl.workflow.FlowGraphEndPoint
nodeKey
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
equals(Object obj)
int
hashCode()
String
toString()
-
Methods inherited from class de.xima.fc.mdl.workflow.FlowGraphEndPoint
controlTransfer, getNodeKey, normal, returning, throwing
-
-
-
-
Method Detail
-
equals
public boolean equals(Object obj)
- Specified by:
equals
in classFlowGraphEndPoint
-
hashCode
public int hashCode()
- Specified by:
hashCode
in classFlowGraphEndPoint
-
-