]> gerrit.simantics Code Review - simantics/platform.git/blobdiff - bundles/org.simantics.db.indexing/src/org/simantics/db/indexing/QueryIndexResources.java
Fixed all line endings of the repository
[simantics/platform.git] / bundles / org.simantics.db.indexing / src / org / simantics / db / indexing / QueryIndexResources.java
index 2d50f2242c92509ac79398b3c28f55fbd826aaa9..118ce149c5ef94fb9515160c77b2750237f06b77 100644 (file)
@@ -1,42 +1,42 @@
-package org.simantics.db.indexing;\r
-\r
-import java.util.Collections;\r
-import java.util.List;\r
-\r
-import org.simantics.db.ReadGraph;\r
-import org.simantics.db.Resource;\r
-import org.simantics.db.common.primitiverequest.Adapter;\r
-import org.simantics.db.common.procedure.adapter.TransientCacheListener;\r
-import org.simantics.db.common.request.BinaryRead;\r
-import org.simantics.db.exception.DatabaseException;\r
-import org.simantics.operation.Layer0X;\r
-import org.simantics.scl.runtime.function.Function;\r
-\r
-/**\r
- * A (cacheable) query to optimize single index queries for immutable\r
- * indexes such as ontologies.\r
- */\r
-class QueryIndexResources extends BinaryRead<Resource, String, List<Resource>> {\r
-\r
-       public QueryIndexResources(Resource index, String filter) {\r
-               super(index, filter);\r
-       }\r
-\r
-       @Override\r
-       public List<Resource> perform(ReadGraph graph) throws DatabaseException {\r
-\r
-               Layer0X L0X = Layer0X.getInstance(graph);\r
-\r
-               @SuppressWarnings({ "unchecked", "rawtypes" })\r
-               Function dependencies = graph.syncRequest(new Adapter(L0X.DependencyResources, Function.class), TransientCacheListener.<Function>instance());\r
-\r
-               @SuppressWarnings("unchecked")\r
-               List<Resource> results = (List<Resource>)dependencies.apply(graph, parameter, parameter2);\r
-               if (results == null || results.isEmpty())\r
-                       return Collections.emptyList();\r
-\r
-               return results;\r
-\r
-       }\r
-\r
+package org.simantics.db.indexing;
+
+import java.util.Collections;
+import java.util.List;
+
+import org.simantics.db.ReadGraph;
+import org.simantics.db.Resource;
+import org.simantics.db.common.primitiverequest.Adapter;
+import org.simantics.db.common.procedure.adapter.TransientCacheListener;
+import org.simantics.db.common.request.BinaryRead;
+import org.simantics.db.exception.DatabaseException;
+import org.simantics.operation.Layer0X;
+import org.simantics.scl.runtime.function.Function;
+
+/**
+ * A (cacheable) query to optimize single index queries for immutable
+ * indexes such as ontologies.
+ */
+class QueryIndexResources extends BinaryRead<Resource, String, List<Resource>> {
+
+       public QueryIndexResources(Resource index, String filter) {
+               super(index, filter);
+       }
+
+       @Override
+       public List<Resource> perform(ReadGraph graph) throws DatabaseException {
+
+               Layer0X L0X = Layer0X.getInstance(graph);
+
+               @SuppressWarnings({ "unchecked", "rawtypes" })
+               Function dependencies = graph.syncRequest(new Adapter(L0X.DependencyResources, Function.class), TransientCacheListener.<Function>instance());
+
+               @SuppressWarnings("unchecked")
+               List<Resource> results = (List<Resource>)dependencies.apply(graph, parameter, parameter2);
+               if (results == null || results.isEmpty())
+                       return Collections.emptyList();
+
+               return results;
+
+       }
+
 }
\ No newline at end of file