Пример #1
0
 public void Dispose()
 {
     if (fileSystemChangeMonitor != null)
     {
         fileSystemChangeMonitor.EnableRaisingEvents = false;
         fileSystemChangeMonitor.Dispose();
         fileSystemChangeMonitor = null;
     }
 }
 public void Dispose()
 {
     if (fileSystemChangeMonitor != null)
     {
         fileSystemChangeMonitor.EnableRaisingEvents = false;
         fileSystemChangeMonitor.Dispose();
         fileSystemChangeMonitor = null;
     }
 }
Пример #3
0
 public FileSystemSubdirectoriesMonitor(string directoryFullPath)
 {
     this.directoryFullPath  = directoryFullPath;
     fileSystemChangeMonitor = new FileSystemChangeMonitor
     {
         FullPath              = directoryFullPath,
         NotifyFilter          = NotifyFilters.DirectoryName,
         IncludeSubdirectories = false
     };
     fileSystemChangeMonitor.EnableRaisingEvents = true;
 }
 public FileSystemSubdirectoriesMonitor(string directoryFullPath)
 {
     this.directoryFullPath = directoryFullPath;
     fileSystemChangeMonitor = new FileSystemChangeMonitor
     {
         FullPath = directoryFullPath,
         NotifyFilter = NotifyFilters.DirectoryName,
         IncludeSubdirectories = false
     };
     fileSystemChangeMonitor.EnableRaisingEvents = true;
 }