3 implementations of IFileChangeContext
Microsoft.CodeAnalysis.LanguageServer (2)
HostWorkspace\FileWatching\DefaultFileChangeWatcher.FileChangeContext.cs (1)
22internal sealed class FileChangeContext : IFileChangeContext, IEventRaiser
HostWorkspace\FileWatching\LspFileChangeWatcher.cs (1)
47private sealed class FileChangeContext : IFileChangeContext
Microsoft.VisualStudio.LanguageServices (1)
ProjectSystem\FileChangeWatcher.cs (1)
339private sealed class Context : IVsFreeThreadedFileChangeEvents2, IFileChangeContext
58 references to IFileChangeContext
Microsoft.CodeAnalysis.LanguageServer (6)
HostWorkspace\FileWatching\DefaultFileChangeWatcher.cs (1)
32public IFileChangeContext CreateContext(ImmutableArray<WatchedDirectory> watchedDirectories)
HostWorkspace\FileWatching\DelegatingFileChangeWatcher.cs (1)
44public IFileChangeContext CreateContext(ImmutableArray<WatchedDirectory> watchedDirectories)
HostWorkspace\FileWatching\LspFileChangeWatcher.cs (1)
44public IFileChangeContext CreateContext(ImmutableArray<WatchedDirectory> watchedDirectories)
HostWorkspace\LoadedProject.cs (3)
26private readonly IFileChangeContext _sourceFileChangeContext; 27private readonly IFileChangeContext _projectFileChangeContext; 28private readonly IFileChangeContext _assetsFileChangeContext;
Microsoft.CodeAnalysis.LanguageServer.UnitTests (40)
DefaultFileChangeWatcherTests.cs (38)
23using var context = watcher.CreateContext([]); 34using var context = watcher.CreateContext([new WatchedDirectory(tempDirectory.Path, extensionFilters: [])]); 45using var context = watcher.CreateContext([new WatchedDirectory(nonExistentPath, extensionFilters: [])]); 59using var context = watcher.CreateContext([ 74using var context = watcher.CreateContext([new WatchedDirectory(tempDirectory.Path, extensionFilters: [".cs"])]); 89using var context = watcher.CreateContext([new WatchedDirectory(watchedDir.Path, extensionFilters: [])]); 103using var context = watcher.CreateContext([new WatchedDirectory(tempDirectory.Path, extensionFilters: [".cs"])]); 117using var context = watcher.CreateContext([new WatchedDirectory(tempDirectory.Path, extensionFilters: [".cs"])]); 131using var context = watcher.CreateContext([]); 150using var context = watcher.CreateContext([new WatchedDirectory(tempDirectory.Path, extensionFilters: [])]); 163using var context = watcher.CreateContext([]); 179using var context = watcher.CreateContext([new WatchedDirectory(tempDirectory.Path, extensionFilters: [".cs", ".vb"])]); 203using var context = watcher.CreateContext([new WatchedDirectory(tempDirectory.Path, extensionFilters: [".cs"])]); 219using var context = watcher.CreateContext([new WatchedDirectory(watchedDir.Path, extensionFilters: [])]); 234using var context = watcher.CreateContext([new WatchedDirectory(watchedDir.Path, extensionFilters: [])]); 248using var context = watcher.CreateContext([]); 295using var context = watcher.CreateContext([new WatchedDirectory(tempDirectory.Path, extensionFilters: [])]); 317using var context = watcher.CreateContext([new WatchedDirectory(tempDirectory.Path, extensionFilters: [])]); 339using var context = watcher.CreateContext([new WatchedDirectory(tempDirectory.Path, extensionFilters: [])]); 358using var context = watcher.CreateContext([new WatchedDirectory(tempDirectory.Path, extensionFilters: [".cs"])]); 378using var context = watcher.CreateContext([new WatchedDirectory(tempDirectory.Path, extensionFilters: [".cs"])]); 398using var context = watcher.CreateContext([new WatchedDirectory(tempDirectory.Path, extensionFilters: [])]); 418using var context = watcher.CreateContext([]); 444using var context = watcher.CreateContext([]); 466using var context = watcher.CreateContext([]); 492using var context = watcher.CreateContext([new WatchedDirectory(tempDirectory.Path, extensionFilters: [])]); 529using var context = watcher.CreateContext([new WatchedDirectory(tempDirectory.Path, extensionFilters: [])]); 552using var context = watcher.CreateContext([new WatchedDirectory(tempDirectory.Path, extensionFilters: [])]); 574using var context1 = watcher.CreateContext([new WatchedDirectory(tempDirectory.Path, extensionFilters: [])]); 575using var context2 = watcher.CreateContext([new WatchedDirectory(tempDirectory.Path, extensionFilters: [".cs"])]); 591var context1 = watcher.CreateContext([new WatchedDirectory(tempDirectory.Path, extensionFilters: [])]); 592var context2 = watcher.CreateContext([new WatchedDirectory(tempDirectory.Path, extensionFilters: [".cs"])]); 617using var context1 = watcher.CreateContext([new WatchedDirectory(tempDirectory.Path, extensionFilters: [])]); 618using var context2 = watcher.CreateContext([new WatchedDirectory(tempDirectory.Path, extensionFilters: [".cs"])]); 642var context1 = watcher.CreateContext([new WatchedDirectory(tempDirectory.Path, extensionFilters: [])]); 643using var context2 = watcher.CreateContext([new WatchedDirectory(tempDirectory.Path, extensionFilters: [".cs"])]); 670var context1 = watcher.CreateContext([new WatchedDirectory(tempDirectory.Path, extensionFilters: [])]); 676using var context2 = watcher.CreateContext([new WatchedDirectory(tempDirectory.Path, extensionFilters: [])]);
LspFileChangeWatcherTests.cs (2)
60var context = lspFileChangeWatcher.CreateContext([new ProjectSystem.WatchedDirectory(tempDirectory.Path, extensionFilters: [])]); 90var context = lspFileChangeWatcher.CreateContext([]);
Microsoft.CodeAnalysis.Workspaces (9)
Workspace\ProjectSystem\FileWatchedPortableExecutableReferenceFactory.cs (3)
30private readonly Lazy<IFileChangeContext> _fileReferenceChangeContext; 67_fileReferenceChangeContext = new Lazy<IFileChangeContext>(() => 69var fileReferenceChangeContext = fileChangeWatcher.CreateContext(GetAdditionalWatchedDirectories());
Workspace\ProjectSystem\IFileChangeWatcher.cs (5)
13IFileChangeContext CreateContext(ImmutableArray<WatchedDirectory> watchedDirectories); 17/// Gives a hint to the <see cref="IFileChangeContext"/> that we should watch a top-level directory for all changes in addition 18/// to any files called by <see cref="IFileChangeContext.EnqueueWatchingFile(string)"/>. 21/// This is largely intended as an optimization; consumers should still call <see cref="IFileChangeContext.EnqueueWatchingFile(string)" /> 82/// file in the directory if the <see cref="IFileChangeContext"/> was watching a directory.
Workspace\ProjectSystem\ProjectSystemProject.cs (1)
111private readonly IFileChangeContext _documentFileChangeContext;
Microsoft.VisualStudio.LanguageServices (3)
ProjectSystem\FileChangeWatcher.cs (2)
26/// an <see cref="IFileChangeContext"/> which lets you add/remove files being watched, and an event is raised when a file is modified. 88public IFileChangeContext CreateContext(ImmutableArray<WatchedDirectory> watchedDirectories)
ProjectSystem\RuleSets\VisualStudioRuleSetManager.RuleSetFile.cs (1)
26private IFileChangeContext _fileChangeContext;