X-Git-Url: https://gerrit.simantics.org/r/gitweb?p=simantics%2Fplatform.git;a=blobdiff_plain;f=bundles%2Forg.simantics.structural2%2Fsrc%2Forg%2Fsimantics%2Fstructural2%2Fvariables%2FConnectionBrowser.java;h=60fee19b20b9298aebe90b086d4788f445ad9b8a;hp=b2b92039f87f4f35870c31ed0564c624a89cec75;hb=2d97029aeaaf5d6a965eae98c1646eef29ae2f8b;hpb=25ff14b9cb52ccec8a7d6117f089d9ccbbb08ce2 diff --git a/bundles/org.simantics.structural2/src/org/simantics/structural2/variables/ConnectionBrowser.java b/bundles/org.simantics.structural2/src/org/simantics/structural2/variables/ConnectionBrowser.java index b2b92039f..60fee19b2 100644 --- a/bundles/org.simantics.structural2/src/org/simantics/structural2/variables/ConnectionBrowser.java +++ b/bundles/org.simantics.structural2/src/org/simantics/structural2/variables/ConnectionBrowser.java @@ -17,7 +17,6 @@ import org.simantics.db.common.procedure.adapter.TransientCacheAsyncListener; import org.simantics.db.common.request.BinaryRead; import org.simantics.db.common.request.ResourceRead; import org.simantics.db.common.request.TransientUnaryRead; -import org.simantics.db.common.utils.CommonDBUtils; import org.simantics.db.common.utils.NameUtils; import org.simantics.db.common.utils.NearestOwnerFinder; import org.simantics.db.exception.DatabaseException; @@ -36,8 +35,6 @@ import org.simantics.structural2.Functions.InterfaceResolution; import org.simantics.structural2.queries.ConnectionSet; import org.simantics.structural2.utils.StructuralUtils; import org.simantics.structural2.utils.StructuralUtils.StructuralComponentClass; -import org.simantics.structural2.variables.StandardProceduralChildVariable.FixedConnection; -import org.simantics.utils.datastructures.Pair; import gnu.trove.map.hash.THashMap; import gnu.trove.set.hash.THashSet; @@ -338,14 +335,9 @@ public class ConnectionBrowser { Variable conn = child.getPossibleProperty(graph, cp); FixedConnection fc = (FixedConnection)conn.getValue(graph); - Set result = new THashSet(1+fc.cps.size()); - result.add(new ComponentConnectionDescriptor(child, cp));// (graph, STR, curConfiguration, "/" + c.name + "#" + conn.getName(graph))); - for(Pair cpzz : fc.cps) { - if(cpzz.first == null) { - throw new DatabaseException("Lifted connection was not resolved."); - } - result.add(new PairConnectionDescriptor(curConfiguration, cpzz)); - } + Set result = new THashSet(1+fc.size()); + result.add(new ComponentConnectionDescriptor(child, cp)); + fc.addConnectionDescriptors(graph, curConfiguration, result); return result; } else {