Hey all,

I'm trying to create a directory monitor that will watch a certain directory and print changes made to that directory. I was wondering if there were any C/C++ libraries that provide an abstract class to access the file system on any OS. I would like the program to be multi-platform and fast so C/C++ seems like the right language.

Any suggestions??

Thanks

There are plenty of classes around that abstract out file systems and directories. They take care of things like path separators, os directory calls, etc. If I remember all the following have something: Boost, ACE POCO, QT.

On Linux you probably want to take a look at "inotify", which gives you an OS hook. Linux will notify you of any file events on a directory or file that you register for I don't do enough Windows stuff to know if there is an analog but I seem to remember something very similar to inotify in the .Net api so it must hook into the Windows OS somehow.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.