Class FilesystemWatcher
java.lang.Object
is.galia.util.FilesystemWatcher
Watches a directory for changes to files contained within.
Based on
Watching a Directory for Changes.
-
Nested Class Summary
Nested Classes -
Constructor Summary
ConstructorsConstructorDescriptionFilesystemWatcher
(Path dir, FilesystemWatcher.Callback callback) Creates aWatchService
and registers the given directory. -
Method Summary
-
Constructor Details
-
FilesystemWatcher
Creates aWatchService
and registers the given directory.- Throws:
IOException
-
-
Method Details
-
start
public void start()Starts watching for changes. This will block, so is normally invoked in a separate thread. -
stop
public void stop()
-