|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.cip4.jdflib.util.hotfolder.HotFolder
public class HotFolder
a very simple hotfolder watcher subdirectories are ignored
| Nested Class Summary | |
|---|---|
protected class |
HotFolder.ExtensionListener
simple container class that retains the last known mod date of a file |
protected class |
HotFolder.FileTime
simple container class that retains the last known mod date of a file |
| Field Summary | |
|---|---|
static int |
defaultStabilizeTime
the default time time in milliseconds to wait for stabilization |
protected Vector<HotFolder.ExtensionListener> |
hfl
|
int |
stabilizeTime
the time in milliseconds to wait for stabilization |
| Constructor Summary | |
|---|---|
HotFolder(File _dir)
Deprecated. - use the 3 parameter version |
|
HotFolder(File _dir,
String ext,
HotFolderListener _hfl)
constructor for a simple hotfolder watcher that is automagically started in its own thread |
|
| Method Summary | |
|---|---|
void |
addListener(HotFolderListener _hfl,
String ext)
|
static int |
getDefaultStabilizeTime()
|
File |
getDir()
|
int |
getStabilizeTime()
|
void |
restart()
restart the thread |
void |
run()
run the listener thread... |
static void |
setDefaultStabilizeTime(int defaultStabilizeTime)
|
void |
setStabilizeTime(int stabilizeTime)
|
void |
stop()
stop this thread; |
String |
toString()
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
public static int defaultStabilizeTime
public int stabilizeTime
protected final Vector<HotFolder.ExtensionListener> hfl
| Constructor Detail |
|---|
@Deprecated public HotFolder(File _dir)
_dir - the Directory to watch
public HotFolder(File _dir,
String ext,
HotFolderListener _hfl)
_dir - the Directory to watchext - the extension filter - case is ignored and lists of extensions may be specified as a comma separated list e.g. ".txt,.xml"_hfl - the listener callback| Method Detail |
|---|
public File getDir()
public void addListener(HotFolderListener _hfl,
String ext)
_hfl - ext - public void restart()
public void stop()
public void run()
run in interface RunnableRunnable.run()public String toString()
toString in class ObjectObject.toString()public static int getDefaultStabilizeTime()
public static void setDefaultStabilizeTime(int defaultStabilizeTime)
defaultStabilizeTime - the defaultStabilizeTime to setpublic int getStabilizeTime()
public void setStabilizeTime(int stabilizeTime)
stabilizeTime - the stabilizeTime to set
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||