Notifies a delegate about changes to a file or folder.
Definition at line 39 of file VuoFileWatcher.hh.
Public Member Functions | |
VuoFileWatcher (VuoFileWatcherDelegate *delegate, const string &fileToWatch, bool persistent=true) | |
Starts watching a file or folder. More... | |
~VuoFileWatcher () | |
Stops watching the folder. More... | |
VuoFileWatcher::VuoFileWatcher | ( | VuoFileWatcherDelegate * | delegate, |
const string & | fileOrFolderToWatch, | ||
bool | persistent = true |
||
) |
Starts watching a file or folder.
If persistent is true: If the file/folder doesn't exist, or exists and is later deleted or moved/renamed, it is periodically checked for existence, then watching begins (again).
If persistent is false: If the file/folder doesn't exist, this class instance does nothing. If the file/folder exists and is later deleted or moved/renamed, this class instance stops watching it (even if another file/folder with the same name later reappears, or if the same file/folder is renamed back into place).
Definition at line 30 of file VuoFileWatcher.cc.
VuoFileWatcher::~VuoFileWatcher | ( | ) |
Stops watching the folder.
Definition at line 285 of file VuoFileWatcher.cc.