补上一个提交

This commit is contained in:
mxd 2020-03-25 19:18:50 +08:00
parent 9deb98ba54
commit 0487423365

View File

@ -31,6 +31,16 @@ public class SpiderNode {
* 节点流转条件
*/
private Map<String,String> condition = new HashMap<>();
/**
* 异常流转
*/
private Map<String,String> exception = new HashMap<>();
/**
* 传递变量
*/
private Map<String,String> transmitVariable = new HashMap<>();
/**
* 节点名称
*/
@ -106,6 +116,23 @@ public class SpiderNode {
this.nextNodes.add(nextNode);
}
public String getExceptionFlow(String fromNodeId) {
return exception.get(fromNodeId);
}
public boolean isTransmitVariable(String fromNodeId) {
String value = transmitVariable.get(fromNodeId);
return value == null || "1".equalsIgnoreCase(value);
}
public void setTransmitVariable(String fromNodeId,String value){
this.transmitVariable.put(fromNodeId,value);
}
public void setExceptionFlow(String fromNodeId,String value){
this.exception.put(fromNodeId,value);
}
public List<SpiderNode> getNextNodes() {
return nextNodes;
}