about.text = Simantics System Dynamics\n\\r
\n\\r
-Version 1.7.0\n\\r
+Version 1.8.0\n\\r
\n\\r
-Copyright (c) 2013 Association for Decentralized Information Management in Industry THTH ry.\n\\r
+Copyright (c) 2014 Association for Decentralized Information Management in Industry THTH ry.\n\\r
\n\\r
Contributors:\n\\r
VTT Technical Research Centre of Finland\n\\r
public SearchResult apply(IProgressMonitor monitor, ReadGraph graph, Resource model, SearchQuery query, Integer maxResults) {\r
try {\r
String origQuery = query.getOriginalQuery();\r
+ SearchQuery wildcardedQuery;\r
if (!origQuery.isEmpty()) // Add asterisks for performSearch \r
- query.setOriginalQuery("*" + origQuery + "*");\r
+ wildcardedQuery = query.withOriginalQuery("*" + origQuery + "*");\r
+ else\r
+ wildcardedQuery = query.withOriginalQuery("*");\r
\r
- // Check whether only currently open diagram is searched\r
- String filteredQuery = query.getQuery("Name","Types");\r
+ String filteredQuery = wildcardedQuery.escaped(false).getQuery("Name","Types");\r
Collection<Map<String, Object>> results = Searching.performSearch(graph, \r
Layer0X.getInstance(graph).Dependencies, \r
model, \r
filteredQuery, \r
MAX_RESULTS);\r
\r
- query.setOriginalQuery(origQuery); // Restore the original query without *'s\r
- \r
+ // Check whether only currently open diagram is searched\r
if (!query.getSearchParams().contains(FindSearchTrim.CURRENT_DIAGRAM_OPTION))\r
return generateSearchResults(graph, results, Scope.ALL_MODELS);\r
else\r