]> gerrit.simantics Code Review - simantics/platform.git/blobdiff - bundles/org.simantics.structural2/src/org/simantics/structural2/utils/StructuralUtils.java
Multiple readers and variable optimization
[simantics/platform.git] / bundles / org.simantics.structural2 / src / org / simantics / structural2 / utils / StructuralUtils.java
index 9a77d100fca3ded3b6924aee9915d05119f52ecb..3181dd7c45d7ea2434eed586393a2d2c7127c5b2 100644 (file)
@@ -265,7 +265,7 @@ public class StructuralUtils {
        if(property == null) return null;
        Connection conn = property.getPossibleValue(graph);
        if(conn == null) return null;
-       Collection<Variable> cps = conn.getConnectionPoints(graph, null);
+       Collection<Variable> cps = conn.getConnectionPoints(graph, component, null);
        if(cps.size() == 2) {
                for(Variable var : cps) {
                        if(property.equals(var)) continue;
@@ -287,8 +287,8 @@ public class StructuralUtils {
                 ;
     }
     
-    public static List<Variable> structuralConnectionConnectionPoints(ReadGraph graph, Connection conn, Resource relationType) throws DatabaseException {
-       return new ArrayList<Variable>(conn.getConnectionPoints(graph, relationType));
+    public static List<Variable> structuralConnectionConnectionPoints(ReadGraph graph, Variable component, Connection conn, Resource relationType) throws DatabaseException {
+       return new ArrayList<Variable>(conn.getConnectionPoints(graph, component, relationType));
     }
 
 }