开发者

FileSystemWatcher blacklist?

开发者 https://www.devze.com 2023-02-11 07:39 出处:网络
The FileSystemWatcher class here: http://msdn.microsoft.com/en-us/library/system.io.filesystemwatcher.aspx

The FileSystemWatcher class here:

http://msdn.microsoft.com/en-us/library/system.io.filesystemwatcher.aspx

Has a filter property to let you specify what files you want to monitor (like a whitelist). Is there a way to specify what files you dont want to monitor? (like a blacklist)

I currently have a wr开发者_如何学JAVAapper for the FileSystemWatcher class that traps each event and compares it with a list of paths to ignore but it doesn't work perfectly and I though that before spending a long time debugging it, I would ask if there is a built in way to do that.


No, there is no "blacklist" feature for FileSystemWatcher.

0

精彩评论

暂无评论...
验证码 换一张
取 消