From: miettinen Date: Fri, 5 Jul 2013 11:45:13 +0000 (+0000) Subject: SearchTrim function to collect search results from multiple SearchResults (refs ... X-Git-Tag: 1.8.1~268 X-Git-Url: https://gerrit.simantics.org/r/gitweb?a=commitdiff_plain;h=be926849c4093d24f387ba845a07cff69ba3779e;p=simantics%2Fsysdyn.git SearchTrim function to collect search results from multiple SearchResults (refs #3966). git-svn-id: https://www.simantics.org/svn/simantics/sysdyn/trunk@27695 ac1ea38d-2e2b-0410-8846-a27921b304fc --- diff --git a/org.simantics.sysdyn.ui/src/org/simantics/sysdyn/ui/function/ModulesSearchFunction.java b/org.simantics.sysdyn.ui/src/org/simantics/sysdyn/ui/function/ModulesSearchFunction.java index d584a70e..ba8f42a1 100644 --- a/org.simantics.sysdyn.ui/src/org/simantics/sysdyn/ui/function/ModulesSearchFunction.java +++ b/org.simantics.sysdyn.ui/src/org/simantics/sysdyn/ui/function/ModulesSearchFunction.java @@ -30,6 +30,7 @@ import org.simantics.diagram.stubs.DiagramResource; import org.simantics.layer0.Layer0; import org.simantics.operation.Layer0X; import org.simantics.scl.runtime.function.FunctionImpl4; +import org.simantics.scl.runtime.function.FunctionImpl5; import org.simantics.sysdyn.SysdynResource; import org.simantics.workbench.search.NamedResource; import org.simantics.workbench.search.QueryResult; @@ -45,13 +46,13 @@ import freemarker.template.TemplateException; * * @author Tuukka Lehtonen */ -public class ModulesSearchFunction extends FunctionImpl4> { +public class ModulesSearchFunction extends FunctionImpl5> { @Override - public Collection apply(IProgressMonitor monitor, ReadGraph graph, String query, Integer maxResults) { + public Collection apply(IProgressMonitor monitor, ReadGraph graph, Resource model, String query, Integer maxResults) { try { Collection> results = Searching.performSearch(graph, - Layer0X.getInstance(graph).Dependencies, query, maxResults); + Layer0X.getInstance(graph).Dependencies, model, query, maxResults); return generateSearchResults(graph, results); } catch (DatabaseException e) {