My question would be how often do you need an update? As soon as the file is updated or on the hour or what?
Is there any C API using which my process can register a callback with the OS for informing my process whenever a file is updated (i.e., the time stamp of the file undergoes a change).
I have some experience of working in Windows OS and there is some facility available there.
In linux I was not getting such an API. What I am now thinking of doing is to run a thread which monitors the file timestamp with a periodicity. Though this would serve my purpose but it is not a very performant solution. Besides it is also not possible to continuously monitor and so instantaneous notification upon update is not possible.
If anyone knows of some direct and better way pls help.
My question would be how often do you need an update? As soon as the file is updated or on the hour or what?
If you give a man a fire he'll be warm, if you light the man on fire he'll be warm for life.
You say you have some experience working in Windows. If you tell us what facility you use on Windows, we might be able to find an equivalent for you. I have experience with both Windows and Linux programming, but am not familiar with any API that handles the scenario you've mentioned on either platform.
Let us know what you use and we'll see what we can come up with. (I do have one possible work-around, but it's pure theory at this point and I don't want to recommend it until other possible resources are tried first.)
Inotify:
http://www.kernel.org/pub/linux/kern...e/rml/inotify/
Might want to take a look at something like beagle, that uses it
http://beaglewiki.org
whatdoyougetwhenyoumultiplysixbynine??
Bookmarks