|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectxflow.common.Node
The Node class represents a node in a directed graph. A directed graph is used to represent a workflow model.
| Field Summary | |
static java.lang.String |
AND
|
static java.lang.String |
CONTAINER
|
static java.lang.String |
END
|
static java.lang.String |
OR
|
static java.lang.String |
PROCESS
|
static java.lang.String |
START
|
| Constructor Summary | |
Node()
|
|
Node(int nodeId)
Constructs a new node |
|
Node(java.lang.String nodeName,
java.lang.String nodeType)
Constructs a new node |
|
| Method Summary | |
void |
addDestination(Node node,
java.lang.String rule)
Adds a destination and a rule to evaluate a workflowobject's transition to this destination. |
void |
addFromNode(Node node)
Adds a fromNode to this node |
boolean |
detectCycle()
Detects if the graph contains cycles. |
void |
expand()
Recursively loads this node and all nodes reachable from this node from database. |
java.lang.String |
getContainee()
Returns the node's containee graph name. |
int |
getContaineeVersion()
Returns the node's containee graph version. |
java.lang.String |
getDescription()
Returns node description |
java.util.List |
getDestinations()
|
java.util.List |
getFromNodes()
|
java.lang.String |
getName()
|
Node |
getNode(int nodeId)
Finds and returns a node within a graph given a node ID |
Node |
getNode(java.lang.String name)
Finds and returns a node within a graph given a node name |
int |
getNodeId()
Returns the node ID |
java.lang.Integer |
getNodeIdAsInteger()
Returns the node ID |
java.lang.String |
getNodeName()
Deprecated. use getName Returns the node name |
java.util.List |
getNodes()
|
java.util.List |
getNodes(java.lang.String nodeType)
|
java.lang.String |
getNodeType()
Returns the node type |
java.lang.Object |
getProperty(java.lang.String key)
Gets a node's property |
java.lang.String |
getTimeoutHandler()
Gets the timeout handler for a Process node |
int |
getTimeoutMinutes()
Gets the timeout for a Process node |
java.lang.String |
getType()
|
boolean |
isValidated()
|
void |
print()
Prints out node id and description of node. |
void |
saveDB(int gid)
Recursively saves a node, its destinations and all links between nodes to the database. |
void |
setContainee(java.lang.String graphName)
Sets the node's containee graph name. |
void |
setContaineeVersion(int version)
Sets the node's containee graph version. |
void |
setDescription(java.lang.String d)
Sets the node description |
void |
setDestinations(java.util.List destinations)
|
void |
setName(java.lang.String name)
|
void |
setNodeId(int nodeId)
|
void |
setNodeType(java.lang.String nodeType)
|
void |
setProperty(java.lang.String key,
java.lang.Object value)
Sets a property on a node |
void |
setTimeoutHandler(java.lang.String timeoutHandler)
Sets the timeout handler for a Process node |
void |
setTimeoutMinutes(int timeoutMinutes)
Sets the timeout value for a Process node |
void |
setType(java.lang.String type)
|
void |
setValidated()
|
void |
traverse()
Recursively traverses all the nodes of a graph. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
public static final java.lang.String PROCESS
public static final java.lang.String AND
public static final java.lang.String OR
public static final java.lang.String START
public static final java.lang.String END
public static final java.lang.String CONTAINER
| Constructor Detail |
public Node()
public Node(java.lang.String nodeName,
java.lang.String nodeType)
nodeName - public Node(int nodeId)
nodeId - | Method Detail |
public int getNodeId()
public void setNodeId(int nodeId)
public void setNodeType(java.lang.String nodeType)
public void setDestinations(java.util.List destinations)
public java.lang.Integer getNodeIdAsInteger()
public java.lang.String getType()
public void setType(java.lang.String type)
public java.lang.String getNodeName()
public java.lang.String getName()
public void setName(java.lang.String name)
public java.lang.String getNodeType()
public java.lang.String getDescription()
public void setDescription(java.lang.String d)
d - public java.lang.String getContainee()
public void setContainee(java.lang.String graphName)
graphName - public int getContaineeVersion()
public void setContaineeVersion(int version)
version -
public void expand()
throws java.lang.Exception
java.lang.Exception
public void saveDB(int gid)
throws java.lang.Exception
gid - The graph ID
java.lang.Exceptionpublic boolean detectCycle()
public void traverse()
public void print()
public Node getNode(int nodeId)
nodeId - The node ID for finding
public Node getNode(java.lang.String name)
name - The node name for finding
public void addDestination(Node node,
java.lang.String rule)
node - The destination noderule - The rule for reaching this destinationpublic java.util.List getDestinations()
public void addFromNode(Node node)
node - The from nodepublic java.util.List getFromNodes()
public java.util.List getNodes(java.lang.String nodeType)
public java.util.List getNodes()
public void setProperty(java.lang.String key,
java.lang.Object value)
key - the property namevalue - the property value - must be serializablepublic java.lang.Object getProperty(java.lang.String key)
key - the property name
public void setTimeoutMinutes(int timeoutMinutes)
timeoutMinutes - the timeout in minutespublic int getTimeoutMinutes()
public void setTimeoutHandler(java.lang.String timeoutHandler)
timeoutHandler - the name of the timeout handler (a workflow name)public java.lang.String getTimeoutHandler()
public void setValidated()
public boolean isValidated()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||