4 instantiations of WatcherOperation
Microsoft.VisualStudio.LanguageServices (4)
ProjectSystem\FileChangeWatcher.cs (4)
212=> new(Kind.WatchDirectory, directory, filters, sink, cookies); 218=> new(Kind.WatchFiles, new OneOrMany<string>(files), fileChangeFlags, sink, new OneOrMany<Context.RegularWatchedFile>(tokens)); 221=> new(Kind.UnwatchDirectories, cookies); 224=> new(Kind.UnwatchFiles, new OneOrMany<Context.RegularWatchedFile>(tokens));
22 references to WatcherOperation
Microsoft.VisualStudio.LanguageServices (22)
ProjectSystem\FileChangeWatcher.cs (22)
40private readonly AsyncBatchingWorkQueue<WatcherOperation> _taskQueue; 50_taskQueue = new AsyncBatchingWorkQueue<WatcherOperation>( 57private async ValueTask ProcessBatchAsync(ImmutableSegmentedList<WatcherOperation> operations, CancellationToken cancellationToken) 65var combinedOp = WatcherOperation.CombineRange(operations, startIndex, combinableEndIndex); 74static int FindCombinableRange(ImmutableSegmentedList<WatcherOperation> operations, int startIndex) 211public static WatcherOperation WatchDirectory(string directory, ImmutableArray<string> filters, IVsFreeThreadedFileChangeEvents2 sink, List<uint> cookies) 214public static WatcherOperation WatchFile(string path, _VSFILECHANGEFLAGS fileChangeFlags, IVsFreeThreadedFileChangeEvents2 sink, Context.RegularWatchedFile token) 217public static WatcherOperation WatchFiles(ImmutableArray<string> files, _VSFILECHANGEFLAGS fileChangeFlags, IVsFreeThreadedFileChangeEvents2 sink, ImmutableArray<Context.RegularWatchedFile> tokens) 220public static WatcherOperation UnwatchDirectories(List<uint> cookies) 223public static WatcherOperation UnwatchFiles(ImmutableArray<Context.RegularWatchedFile> tokens) 226public static WatcherOperation UnwatchFile(Context.RegularWatchedFile token) 230/// Combines <see cref="WatcherOperation"/> instances between <paramref name="start"/> and <paramref name="end"/> 238public static WatcherOperation CombineRange(ImmutableSegmentedList<WatcherOperation> operations, int start, int end) 289public bool CanCombineWith(in WatcherOperation other) 366var item = WatcherOperation.WatchDirectory( 388_fileChangeWatcher._taskQueue.AddWork(WatcherOperation.UnwatchDirectories(_directoryWatchCookies)); 389_fileChangeWatcher._taskQueue.AddWork(WatcherOperation.UnwatchFiles(_activeFileWatchingTokens.ToImmutableArray())); 405_fileChangeWatcher._taskQueue.AddWork(WatcherOperation.WatchFile(filePath, _VSFILECHANGEFLAGS.VSFILECHG_Size | _VSFILECHANGEFLAGS.VSFILECHG_Time, this, token)); 417_fileChangeWatcher._taskQueue.AddWork(WatcherOperation.UnwatchFile(watchedFile));