I think you are looking for android.os.FileObserver.
You implement a subclass of it, which implements onEvent().
Then you construct a new instance of this class with the file path and maybe flags as parameters. After calling startWatching() your callback should be invoked with file changes.
Thanks for you replay, I ever tried FileObserver, it only can monitor the registered file or files just under the registered path, But I want to monitor the files under the registered path RECUSIVELY.
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.