X-Git-Url: https://gerrit.simantics.org/r/gitweb?p=simantics%2Fplatform.git;a=blobdiff_plain;f=bundles%2Forg.simantics.modeling%2Fsrc%2Forg%2Fsimantics%2Fmodeling%2Fadapters%2FExistingInstancesRemover.java;h=84c0f4151d5b4f0c437d301cd9f1d920208b57fa;hp=787a400f9439022a4346532bd3c6fce3471127fe;hb=ad0e5bf4b34705988e23c9ee3f8e4fcbb760c701;hpb=0f2d6b33db9eabe0c1b142f6d0197a5d1446c3b1 diff --git a/bundles/org.simantics.modeling/src/org/simantics/modeling/adapters/ExistingInstancesRemover.java b/bundles/org.simantics.modeling/src/org/simantics/modeling/adapters/ExistingInstancesRemover.java index 787a400f9..84c0f4151 100644 --- a/bundles/org.simantics.modeling/src/org/simantics/modeling/adapters/ExistingInstancesRemover.java +++ b/bundles/org.simantics.modeling/src/org/simantics/modeling/adapters/ExistingInstancesRemover.java @@ -90,23 +90,6 @@ public class ExistingInstancesRemover extends AbstractRemover { if (indexRoot == null) return Collections.emptySet(); -// @SuppressWarnings("rawtypes") -// Function modules = graph.adapt(Layer0X.getInstance(graph).Dependencies, Function.class); -// @SuppressWarnings("unchecked") -// List> result = (List>) modules.apply(graph, root, "Types:\"" + IndexQueries.escape(componentTypeName) + "\""); -// if (result.isEmpty()) { -// justRemove(graph); -// return; -// } -// -// final Set instances = new HashSet(); -// for (Map entry : result) { -// Resource c = (Resource) entry.get(Dependencies.FIELD_RESOURCE); -// if (c != null && graph.hasStatement(c, L0.InstanceOf, resource)) { -// instances.add(c); -// } -// } - Set result = new THashSet(); Instances search = graph.adapt(type, Instances.class); discoverInstances(graph, type, indexRoot, search, result);