Package org.apache.commons.io.monitor
Interface FileAlterationListener
- All Known Implementing Classes:
FileAlterationListenerAdaptor
public interface FileAlterationListener
Receives events of file system modifications.
Register FileAlterationListener
s with a FileAlterationObserver
.
- Since:
- 2.0
- See Also:
-
Method Summary
Modifier and TypeMethodDescriptionvoid
onDirectoryChange
(File directory) Directory changed Event.void
onDirectoryCreate
(File directory) Directory created Event.void
onDirectoryDelete
(File directory) Directory deleted Event.void
onFileChange
(File file) File changed Event.void
onFileCreate
(File file) File created Event.void
onFileDelete
(File file) File deleted Event.void
onStart
(FileAlterationObserver observer) File system observer started checking event.void
onStop
(FileAlterationObserver observer) File system observer finished checking event.
-
Method Details
-
onDirectoryChange
Directory changed Event.- Parameters:
directory
- The directory changed
-
onDirectoryCreate
Directory created Event.- Parameters:
directory
- The directory created
-
onDirectoryDelete
Directory deleted Event.- Parameters:
directory
- The directory deleted
-
onFileChange
File changed Event.- Parameters:
file
- The file changed
-
onFileCreate
File created Event.- Parameters:
file
- The file created
-
onFileDelete
File deleted Event.- Parameters:
file
- The file deleted
-
onStart
File system observer started checking event.- Parameters:
observer
- The file system observer
-
onStop
File system observer finished checking event.- Parameters:
observer
- The file system observer
-