| Package | Description |
|---|---|
| org.apache.commons.io.monitor |
Provides a component for monitoring file system events (directory and file create, update and delete events).
|
| Modifier and Type | Field and Description |
|---|---|
private FileEntry[] |
FileEntry.children
My children.
|
(package private) static FileEntry[] |
FileEntry.EMPTY_FILE_ENTRY_ARRAY |
private FileEntry |
FileEntry.parent
The parent.
|
private FileEntry |
FileAlterationObserver.rootEntry
The root directory to observe.
|
| Modifier and Type | Method and Description |
|---|---|
private FileEntry |
FileAlterationObserver.createFileEntry(FileEntry parent,
java.io.File file)
Creates a new file entry for the specified file.
|
FileEntry[] |
FileEntry.getChildren()
Gets the directory's files.
|
FileEntry |
FileEntry.getParent()
Gets the parent entry.
|
private FileEntry[] |
FileAlterationObserver.listFileEntries(java.io.File file,
FileEntry entry)
Lists the file entries in
file. |
FileEntry |
FileEntry.newChildInstance(java.io.File file)
Constructs a new child instance.
|
| Modifier and Type | Method and Description |
|---|---|
private void |
FileAlterationObserver.checkAndFire(FileEntry parentEntry,
FileEntry[] previousEntries,
java.io.File[] currentEntries)
Compares two file lists for files which have been created, modified or deleted.
|
private void |
FileAlterationObserver.checkAndFire(FileEntry parentEntry,
FileEntry[] previousEntries,
java.io.File[] currentEntries)
Compares two file lists for files which have been created, modified or deleted.
|
private FileEntry |
FileAlterationObserver.createFileEntry(FileEntry parent,
java.io.File file)
Creates a new file entry for the specified file.
|
private void |
FileAlterationObserver.fireOnChange(FileEntry entry,
java.io.File file)
Fires directory/file change events to the registered listeners.
|
private void |
FileAlterationObserver.fireOnCreate(FileEntry entry)
Fires directory/file created events to the registered listeners.
|
private void |
FileAlterationObserver.fireOnDelete(FileEntry entry)
Fires directory/file delete events to the registered listeners.
|
private FileEntry[] |
FileAlterationObserver.listFileEntries(java.io.File file,
FileEntry entry)
Lists the file entries in
file. |
void |
FileEntry.setChildren(FileEntry... children)
Sets the directory's files.
|
| Constructor and Description |
|---|
FileAlterationObserver(FileEntry rootEntry,
java.io.FileFilter fileFilter,
java.util.Comparator<java.io.File> comparator)
Constructs an observer for the specified directory, file filter and file comparator.
|
FileAlterationObserver(FileEntry rootEntry,
java.io.FileFilter fileFilter,
IOCase ioCase)
Constructs an observer for the specified directory, file filter and file comparator.
|
FileEntry(FileEntry parent,
java.io.File file)
Constructs a new monitor for a specified
File. |