Search in sources :

Example 1 with FileWatcherRegistry

use of org.gradle.internal.watch.registry.FileWatcherRegistry in project gradle by gradle.

the class WatchingVirtualFileSystem method stopWatchingAndInvalidateHierarchy.

private SnapshotHierarchy stopWatchingAndInvalidateHierarchy(SnapshotHierarchy currentRoot) {
    if (watchRegistry != null) {
        try {
            FileWatcherRegistry toBeClosed = watchRegistry;
            watchRegistry = null;
            toBeClosed.close();
        } catch (IOException ex) {
            LOGGER.error("Unable to close file watcher registry", ex);
        }
    }
    return currentRoot.empty();
}
Also used : IOException(java.io.IOException) FileWatcherRegistry(org.gradle.internal.watch.registry.FileWatcherRegistry)

Aggregations

IOException (java.io.IOException)1 FileWatcherRegistry (org.gradle.internal.watch.registry.FileWatcherRegistry)1