public static bool TryAcquireMonitor(this IFileMonitorManager col, string path, Action <IFileMonitor> fileChangeCallback) { IFileMonitor fileMonitor = null; return(col.TryAcquireMonitor(Path.GetDirectoryName(path), Path.GetFileName(path), true, fileChangeCallback, WatcherChangeTypes.All, ref fileMonitor)); }
public static bool TryAcquireMonitor(this IFileMonitorManager col, string directoryPath, string filter, Action <IFileMonitor> fileChangeCallback) { IFileMonitor fileMonitor = null; return(col.TryAcquireMonitor(directoryPath, filter, true, fileChangeCallback, WatcherChangeTypes.All, ref fileMonitor)); }