Using Java over Windows Vista, I'm trying to create a kind of a monitor for a directory, so every time this directory is modified (new, renamed, updated or deleted files) a process is triggered. I tried to do this with a loop that will execute a dir
in the directory and analyze all the files. But this is very time and memory consuming, specially when the number of files start to grow. I think there should be a better way to do that.
note: there is a similar question in SO for this, but it's for C#.