public void close() {
   // This isn't quite right. Should close the worker classpath cache once we're finished with the
   // worker processes. This may be before the end of this build
   // or they may be used across multiple builds
   synchronized (lock) {
     try {
       if (workerClassPathCache != null) {
         workerClassPathCache.close();
       }
     } finally {
       workerClassPathCache = null;
       workerClassPath = null;
     }
   }
 }
 public <K, V> PersistentIndexedCache<K, V> createCache(
     File cacheFile, Class<K> keyType, Class<V> valueType) {
   return cache.createCache(cacheFile, keyType, valueType);
 }
 private static File jarFile(PersistentCache cache) {
   return new File(cache.getBaseDir(), "gradle-worker.jar");
 }
 public <T> T longRunningOperation(String operationDisplayName, Factory<? extends T> action) {
   return cache.longRunningOperation(operationDisplayName, action);
 }
 public void useCache(String operationDisplayName, Runnable action) {
   cache.useCache(operationDisplayName, action);
 }
 public <T> T useCache(String operationDisplayName, Factory<? extends T> action) {
   return cache.useCache(operationDisplayName, action);
 }
 public void longRunningOperation(String operationDisplayName, final Runnable action) {
   cache.longRunningOperation(operationDisplayName, action);
 }
 public File getCacheDir() {
   return cache.getBaseDir();
 }