]> gerrit.simantics Code Review - simantics/platform.git/blobdiff - bundles/org.simantics.graph.compiler/src/org/simantics/graph/compiler/internal/procedures/Compactify.java
Fixed all line endings of the repository
[simantics/platform.git] / bundles / org.simantics.graph.compiler / src / org / simantics / graph / compiler / internal / procedures / Compactify.java
index 82fd5798c09dff76c6e23db5b2979358291e8221..7b647806d87947ee25ee01a01152a90da44d18f2 100644 (file)
@@ -1,32 +1,32 @@
-package org.simantics.graph.compiler.internal.procedures;\r
-\r
-import gnu.trove.map.hash.TIntIntHashMap;\r
-\r
-import org.simantics.graph.store.GraphStore;\r
-\r
-public class Compactify implements Runnable {\r
-       GraphStore store;\r
-\r
-       public Compactify(GraphStore store) {\r
-               this.store = store;\r
-       }\r
-\r
-       @Override\r
-       public void run() {\r
-               // Mark all used resources\r
-               int resourceCount = store.identities.getResourceCount();\r
-               final boolean[] temp = new boolean[resourceCount];\r
-               store.collectReferences(temp);\r
-               \r
-               // Create a map\r
-               int newResourceCount = 0;\r
-               TIntIntHashMap map = new TIntIntHashMap(resourceCount);\r
-               for(int i=0;i<resourceCount;++i)\r
-                       if(temp[i])\r
-                               map.put(i, newResourceCount++);\r
-               if(newResourceCount < resourceCount) {\r
-                       store.map(map);\r
-                       store.identities.setResourceCount(newResourceCount);\r
-               }\r
-       }\r
-}\r
+package org.simantics.graph.compiler.internal.procedures;
+
+import gnu.trove.map.hash.TIntIntHashMap;
+
+import org.simantics.graph.store.GraphStore;
+
+public class Compactify implements Runnable {
+       GraphStore store;
+
+       public Compactify(GraphStore store) {
+               this.store = store;
+       }
+
+       @Override
+       public void run() {
+               // Mark all used resources
+               int resourceCount = store.identities.getResourceCount();
+               final boolean[] temp = new boolean[resourceCount];
+               store.collectReferences(temp);
+               
+               // Create a map
+               int newResourceCount = 0;
+               TIntIntHashMap map = new TIntIntHashMap(resourceCount);
+               for(int i=0;i<resourceCount;++i)
+                       if(temp[i])
+                               map.put(i, newResourceCount++);
+               if(newResourceCount < resourceCount) {
+                       store.map(map);
+                       store.identities.setResourceCount(newResourceCount);
+               }
+       }
+}