CallEdgeAttributeにdelegate前のResourceNodeを持たせるように.
1 parent 5137f73 commit 866878df5b6d4c6095cc188ae6008e8276fcd5d4
k-fujii authored on 21 Jun 2023
Showing 3 changed files
View
4
AlgebraicDataflowArchitectureModel/src/application/editor/stages/ControlFlowDelegationStage.java
graph.getModel().remove(targetEdgeCell);
}
// Insert an edge
CallEdgeAttribute newAttr = new CallEdgeAttribute(targetEdgeAttr.getCallEdge(), dstObjNodeCell, dstNodeCell);
CallEdgeAttribute newAttr = new CallEdgeAttribute(targetEdgeAttr.getCallEdge(), targetEdgeAttr.getOriginalSourceObjectNode(),dstObjNodeCell, dstNodeCell);
graph.insertEdge(controlLayerCell, "", newAttr, dstObjNodeCell, dstNodeCell, "movable=false;");
 
resetGraph();
}
else continue;
if(srcNodeCell == null || dstNodeCell == null) continue;
 
CallEdgeAttribute callEdgeAttr = new CallEdgeAttribute(callEdge, srcNodeCell, dstNodeCell);
CallEdgeAttribute callEdgeAttr = new CallEdgeAttribute(callEdge, (ObjectNode)callEdge.getSource(), srcNodeCell, dstNodeCell);
// If "srcResNode" types of "EntryPointObjectNode" (= channel)
// then parameter references to geometry of "outPort".
if(srcResNode instanceof ResourceNode) {
View
22
AlgebraicDataflowArchitectureModel/src/models/controlFlowModel/CallEdgeAttribute.java
* Information of connection status of the call edge among nodes type of "Object-Node".
*/
public class CallEdgeAttribute extends EdgeAttribute {
private CallEdge callEdge = null;
private ObjectNode orginalSrcObjNode = null;
private mxCell srcCell = null;
private mxCell dstCell = null;
/*************************************************************
* [ *constructor ]
/*************************************************************
*
*/
public CallEdgeAttribute(CallEdge callEdge, ObjectNode originalSrcObjNode, final mxCell srcCell, final mxCell dstCell) {
this.callEdge = callEdge;
this.callEdge.setAttribute(this);
this.orginalSrcObjNode = originalSrcObjNode;
this.srcCell = srcCell;
this.dstCell = dstCell;
}
 
/*************************************************************
*
*/
public CallEdgeAttribute(CallEdge callEdge, final mxCell srcCell, final mxCell dstCell) {
this.srcCell = srcCell;
this.dstCell = dstCell;
}
 
/*************************************************************
* [ *public ]
/*************************************************************
public CallEdge getCallEdge() {
return callEdge;
}
public ObjectNode getOriginalSourceObjectNode() {
return orginalSrcObjNode;
}
public PushPullValue getSelectedOption() {
return callEdge.getSelectedOption();
}
*/
@Override
public String toString() {
String value = "";
value += callEdge.getSelectedOption().name();
if(2 <= callEdge.getSource().getOutEdges( ).size()) {
int order = (((ObjectNode)callEdge.getSource()).getOutEdgeCallOrder(callEdge)+ 1);
value += ":[" + order + "]";
value += "[" + order + "]";
}
return value;
}
View
2
■■■
AlgebraicDataflowArchitectureModel/src/models/controlFlowModel/ObjectNodeAttribute.java
package models.controlFlowModel;
 
import com.mxgraph.model.mxCell;
 
import models.NodeAttribute;
 
/*************************************************************