speedup: call force() only at the end of the build, between chunk builds drop only...
[idea/community.git] / jps / model / src / org / jetbrains / ether / dependencyView / PersistentMaplet.java
index e76e9c045f3cbc4dbfe68395d6ca44e857ef6235..b60661c8948d25ea1432a415e83451a23855195f 100644 (file)
@@ -106,8 +106,13 @@ public class PersistentMaplet<K, V> implements Maplet<K, V> {
     }
   }
 
-  public void flush() {
-    myMap.force();
+  public void flush(boolean memoryCachesOnly) {
+    if (memoryCachesOnly) {
+      myMap.dropMemoryCaches();
+    }
+    else {
+      myMap.force();
+    }
   }
 
   @Override