A watcher of a file system folder.  
 More...
#include <filesystemwatcher.h>
A watcher of a file system folder. 
 
◆ FileSystemWatcher()
Constructs a FileSystemWatcher. 
- Parameters
 - 
  
    | path | The path of the folder to watch  | 
    | includeSubdirectories | Whether or not to include subdirectories for the folder  | 
    | watcherFlags | The flags of what to watch changes for  | 
  
   
- Exceptions
 - 
  
    | std::runtime_error | Thrown if unable to initialize watcher  | 
  
   
 
 
◆ ~FileSystemWatcher()
  
  
      
        
          | Nickvision::Filesystem::FileSystemWatcher::~FileSystemWatcher  | 
          ( | 
           | ) | 
           | 
         
       
   | 
  
noexcept   | 
  
 
 
◆ addExtensionFilter()
  
  
      
        
          | bool Nickvision::Filesystem::FileSystemWatcher::addExtensionFilter  | 
          ( | 
          const std::filesystem::path & |           extension | ) | 
           | 
         
       
   | 
  
noexcept   | 
  
 
Adds an extension of a file to watch for changes in the folder. 
- Parameters
 - 
  
    | extension | The file extension to add  | 
  
   
- Returns
 - True if successful, else false 
 
 
 
◆ changed()
Gets the event for when a watched flag of the folder is changed. 
- Returns
 - The changed event 
 
 
 
◆ clearExtensionFilters()
  
  
      
        
          | bool Nickvision::Filesystem::FileSystemWatcher::clearExtensionFilters  | 
          ( | 
           | ) | 
           | 
         
       
   | 
  
noexcept   | 
  
 
Clears all watched extension filters. This will cause all extensions to be implicitly watched. 
- Returns
 - True if successful, else false 
 
 
 
◆ getIncludeSubdirectories()
  
  
      
        
          | bool Nickvision::Filesystem::FileSystemWatcher::getIncludeSubdirectories  | 
          ( | 
           | ) | 
           const | 
         
       
   | 
  
noexcept   | 
  
 
Gets whether or not subdirectories of the folder are watched. 
- Returns
 - True if subdirectories watched, else false 
 
 
 
◆ getPath()
  
  
      
        
          | const std::filesystem::path & Nickvision::Filesystem::FileSystemWatcher::getPath  | 
          ( | 
           | ) | 
           const | 
         
       
   | 
  
noexcept   | 
  
 
Gets the path of the folder being watched. 
- Returns
 - The path of the folder being watched 
 
 
 
◆ getWatcherFlags()
  
  
      
        
          | WatcherFlags Nickvision::Filesystem::FileSystemWatcher::getWatcherFlags  | 
          ( | 
           | ) | 
           const | 
         
       
   | 
  
noexcept   | 
  
 
Gets the flags of what to watch changes for. 
- Returns
 - The flags of watched properties 
 
 
 
◆ isExtensionWatched()
  
  
      
        
          | bool Nickvision::Filesystem::FileSystemWatcher::isExtensionWatched  | 
          ( | 
          const std::filesystem::path & |           extension | ) | 
           const | 
         
       
   | 
  
noexcept   | 
  
 
Gets whether or not a file extension is being watched. 
- Parameters
 - 
  
    | extension | The file extension to check  | 
  
   
- Returns
 - True if extension is being watched, else false 
 
- 
True if list of extension filters is empty 
 
 
 
◆ removeExtensionFilter()
  
  
      
        
          | bool Nickvision::Filesystem::FileSystemWatcher::removeExtensionFilter  | 
          ( | 
          const std::filesystem::path & |           extension | ) | 
           | 
         
       
   | 
  
noexcept   | 
  
 
Removes an extension of a file to watch for changes in the folder. 
- Parameters
 - 
  
    | extension | The file extension to remove  | 
  
   
- Returns
 - True if successful, else false 
 
 
 
The documentation for this class was generated from the following file: