Apache NetBeans
Apache NetBeans
Latest release

Apache NetBeans 23

Download

I want to listen for changes in a file that may not exist or may be deleted and re-created

There are some cases where you want to listen for changes in a file or folder that does not exist, or may be created and deleted on the fly.

As of NetBeans 6.7, you can use FileUtil.addFileChangeListener(FileChangeListener, File) to listen for such changes. There is also FileUtil.addRecursiveListener