1 write to _project
Microsoft.CodeAnalysis.Workspaces (1)
Workspace\ProjectSystem\ProjectSystemProject.BatchingDocumentCollection.cs (1)
74_project = project;
37 references to _project
Microsoft.CodeAnalysis.Workspaces (37)
Workspace\ProjectSystem\ProjectSystemProject.BatchingDocumentCollection.cs (37)
29/// This class is otherwise free to operate on private members of <see cref="_project"/> if needed.</remarks> 89var documentId = DocumentId.CreateNewId(_project.Id, fullPath); 90var textLoader = _project._projectSystemProjectFactory.CreateFileTextLoader(fullPath); 99using (_project._gate.DisposableWait()) 110_project._documentWatchedFiles.Add(documentId, _project._documentFileChangeContext.EnqueueWatchingFile(fullPath)); 112if (_project._activeBatchScopes > 0) 118_project._projectSystemProjectFactory.ApplyChangeToWorkspace(w => _documentAddAction(w, documentInfo)); 119_project._projectSystemProjectFactory.RaiseOnDocumentsAddedMaybeAsync(useAsync: false, [fullPath]).VerifyCompleted(); 139var documentId = DocumentId.CreateNewId(_project.Id, fullPath); 151using (_project._gate.DisposableWait()) 170if (_project._activeBatchScopes > 0) 176_project._projectSystemProjectFactory.ApplyChangeToWorkspace(w => 178_project._projectSystemProjectFactory.AddDocumentToDocumentsNotFromFiles_NoLock(documentInfo.Id); 195using (_project._gate.DisposableWait()) 202_project._documentWatchedFiles[documentId].Dispose(); 203_project._documentWatchedFiles.Remove(documentId); 219if (_documentAlreadyInWorkspace(_project._projectSystemProjectFactory.Workspace.CurrentSolution, documentId)) 221if (_project._activeBatchScopes > 0) 227_project._projectSystemProjectFactory.ApplyChangeToWorkspace(w => _documentRemoveAction(w, documentId)); 250using (_project._gate.DisposableWait()) 271if (_project._projectSystemProjectFactory.Workspace.CurrentSolution.GetDocument(documentId) != null) 273if (_project._activeBatchScopes > 0) 279_project._projectSystemProjectFactory.ApplyChangeToWorkspace(w => 287_project._projectSystemProjectFactory.RemoveDocumentToDocumentsNotFromFiles_NoLock(documentId); 312using (_project._gate.DisposableWait()) 320using (await _project._gate.DisposableWaitAsync().ConfigureAwait(false)) 323if (_project.HasBeenRemoved) 341documentsToChange.Add((documentId, new WorkspaceFileTextLoader(_project._projectSystemProjectFactory.SolutionServices, filePath, defaultEncoding: null))); 352await _project._projectSystemProjectFactory.ApplyBatchChangeToWorkspaceAsync((solutionChanges, projectUpdateState) => 356if (!_project._projectSystemProjectFactory.Workspace.IsDocumentOpen(documentId)) 379using (_project._gate.DisposableWait()) 400if (_project._activeBatchScopes > 0) 406_project._projectSystemProjectFactory.ApplyChangeToWorkspace(_project.Id, solution => solution.WithProjectDocumentsOrder(_project.Id, documentIds.ToImmutable())); 427addDocumentChangeKind, removeDocuments, removeDocumentChangeKind, _project.Id, _documentsAddedInBatch.ToImmutableArray(),