Package org.hotswap.agent.watch
Interface Watcher
-
- All Known Implementing Classes:
AbstractNIO2Watcher,TreeWatcherNIO,WatcherNIO2
public interface WatcherWatch for change in directory directory tree.- Author:
- Jiri Bubnik
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description voidaddEventListener(ClassLoader classLoader, URI pathPrefix, WatchEventListener listener)Register listeners on an event.voidaddEventListener(ClassLoader classLoader, URL pathPrefix, WatchEventListener listener)Register listeners on an event.voidcloseClassLoader(ClassLoader classLoader)Remove all listeners registered with a classloadervoidrun()Run the watcher agent thread.voidstop()Stop the watcher agent thread.
-
-
-
Method Detail
-
addEventListener
void addEventListener(ClassLoader classLoader, URI pathPrefix, WatchEventListener listener)
Register listeners on an event.- Parameters:
classLoader- the classloader to which this path is associated. May be null, but then this listener will never be disassociated (even if application is undeployed)pathPrefix- where to listenlistener- the listener
-
addEventListener
void addEventListener(ClassLoader classLoader, URL pathPrefix, WatchEventListener listener)
Register listeners on an event.- Parameters:
classLoader- the classloader to which this path is associated. May be null, but then this listener will never be disassociated (even if application is undeployed)pathPrefix- where to listenlistener- the listener
-
closeClassLoader
void closeClassLoader(ClassLoader classLoader)
Remove all listeners registered with a classloader- Parameters:
classLoader- classloadr to close
-
run
void run()
Run the watcher agent thread.
-
stop
void stop()
Stop the watcher agent thread.
-
-