public override IGraphElement[] ModifyNoReuse(LGSPGraph graph, LGSPMatch match) { LGSPNode node_p2 = match.nodes[(int)NodeNums.@p2 - 1]; LGSPNode node_p1 = match.nodes[(int)NodeNums.@p1 - 1]; LGSPEdge edge__edge0 = match.edges[(int)EdgeNums.@_edge0 - 1]; LGSPNode node__node0 = graph.AddNode(NodeType_Process.typeVar); LGSPEdge edge__edge1 = graph.AddEdge(EdgeType_connection.typeVar, node_p1, node__node0); LGSPEdge edge__edge2 = graph.AddEdge(EdgeType_connection.typeVar, node__node0, node_p2); graph.Remove(edge__edge0); return(EmptyReturnElements); }
public static Edge_connection CreateEdge(LGSPGraph graph, LGSPNode source, LGSPNode target) { Edge_connection edge = new Edge_connection(source, target); graph.AddEdge(edge); return(edge); }
public static Edge_slowway CreateEdge(LGSPGraph graph, LGSPNode source, LGSPNode target) { Edge_slowway edge = new Edge_slowway(source, target); graph.AddEdge(edge); return(edge); }