Home » geronimo-2.2-source-release » org.apache.geronimo.deployment.hot » [javadoc | source]
org.apache.geronimo.deployment.hot
public class: DirectoryMonitor [javadoc | source]
java.lang.Object
   org.apache.geronimo.deployment.hot.DirectoryMonitor

All Implemented Interfaces:
    Runnable

Meant to be run as a Thread that tracks the contents of a directory. It sends notifications for changes to its immediate children (it will look into subdirs for changes, but will not send notifications for files within subdirectories). If a file continues to change on every pass, this will wait until it stabilizes before sending an add or update notification (to handle slow uploads, etc.).
Nested Class Summary:
public static interface  DirectoryMonitor.Listener   
Constructor:
 public DirectoryMonitor(File directory,
    Listener listener,
    int pollIntervalMillis) 
Method from org.apache.geronimo.deployment.hot.DirectoryMonitor Summary:
close,   getDirectory,   getListener,   getPollIntervalMillis,   initialize,   isDone,   removeModuleId,   run,   setDirectory,   setListener,   setPollIntervalMillis
Methods from java.lang.Object:
clone,   equals,   finalize,   getClass,   hashCode,   notify,   notifyAll,   toString,   wait,   wait,   wait
Method from org.apache.geronimo.deployment.hot.DirectoryMonitor Detail:
 public synchronized  void close() 
 public File getDirectory() 
 public Listener getListener() 
 public int getPollIntervalMillis() 
 public  void initialize() 
 public synchronized boolean isDone() 
 public  void removeModuleId(Artifact id) 
 public  void run() 
 public  void setDirectory(File directory) 
    Warning: changing the directory at runtime will cause all files in the old directory to be removed and all files in the new directory to be added, next time the thread awakens.
 public  void setListener(Listener listener) 
 public  void setPollIntervalMillis(int pollIntervalMillis)