Does anyone have a FileSystemWatcher-like class in C++/WinAPI?

前端 未结 4 1714
一个人的身影
一个人的身影 2020-12-09 05:52

I need a .Net\'s FileSystemWatcher analog in raw C++/WinAPI. I almost started to code one myself using FindFirstChangeNotification/FindNextChangeNotification, but then it oc

4条回答
  •  渐次进展
    2020-12-09 06:04

    What about the ReadDirectoryChangesW function?

    http://msdn.microsoft.com/en-us/library/aa365465(VS.85).aspx

    It stores notifications in a buffer so you don't miss any changes (unless the buffer overflows)

提交回复
热议问题