Package org.hotswap.agent.watch.nio
Class TreeWatcherNIO
- java.lang.Object
-
- org.hotswap.agent.watch.nio.AbstractNIO2Watcher
-
- org.hotswap.agent.watch.nio.TreeWatcherNIO
-
- All Implemented Interfaces:
Watcher
public class TreeWatcherNIO extends AbstractNIO2Watcher
NIO2 watcher implementation for systems which support ExtendedWatchEventModifier.FILE_TREE (windows)
Java 7 (NIO2) watch a directory (or tree) for changes to files.
- Author:
- alpapad@gmail.com
-
-
Field Summary
-
Fields inherited from class org.hotswap.agent.watch.nio.AbstractNIO2Watcher
classLoaderListeners, dispatcher, keys, KINDS, LOGGER, watcher
-
-
Constructor Summary
Constructors Constructor Description TreeWatcherNIO()Instantiates a new tree watcher nio.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected voidregisterAll(Path dir)Register the given directory, with the WatchService.-
Methods inherited from class org.hotswap.agent.watch.nio.AbstractNIO2Watcher
addDirectory, addEventListener, addEventListener, closeClassLoader, run, stop
-
-
-
-
Constructor Detail
-
TreeWatcherNIO
public TreeWatcherNIO() throws IOExceptionInstantiates a new tree watcher nio.- Throws:
IOException- Signals that an I/O exception has occurred.
-
-
Method Detail
-
registerAll
protected void registerAll(Path dir) throws IOException
Register the given directory, with the WatchService. Sub-directories are automatically watched (filesystem supported)- Specified by:
registerAllin classAbstractNIO2Watcher- Parameters:
dir- the dir- Throws:
IOException- Signals that an I/O exception has occurred.
-
-