1 write to NewProject
Microsoft.CodeAnalysis.Workspaces (1)
Workspace\Solution\ProjectChanges.cs (1)
14
NewProject
= newProject;
63 references to NewProject
AnalyzerRunner (1)
CodeRefactoringRunner.cs (1)
116
return projectChanges[0].
NewProject
.GetDocument(document.Id);
Microsoft.CodeAnalysis.EditorFeatures (2)
Preview\AbstractPreviewFactoryService.cs (2)
90
var newProject = projectChanges.
NewProject
;
229
var newProjectReferences = projectChanges.
NewProject
.ProjectReferences.ToDictionary(r => r.ProjectId);
Microsoft.CodeAnalysis.Features (4)
ExternalAccess\UnitTesting\SolutionCrawler\UnitTestingWorkCoordinator.cs (4)
412
await EnqueueDocumentWorkItemAsync(projectChanges.
NewProject
, addedDocumentId, document: null, UnitTestingInvocationReasons.DocumentAdded).ConfigureAwait(false);
416
await EnqueueChangedDocumentWorkItemAsync(projectChanges.OldProject.GetRequiredDocument(changedDocumentId), projectChanges.
NewProject
.GetRequiredDocument(changedDocumentId))
427
var newProject = projectChanges.
NewProject
;
454
await EnqueueFullProjectWorkItemAsync(projectChanges.
NewProject
, projectConfigurationChange).ConfigureAwait(false);
Microsoft.CodeAnalysis.Workspaces (45)
CodeActions\Operations\ApplyChangesOperation.cs (1)
128
var changedDocument = changedProject.
NewProject
.Solution.GetRequiredTextDocument(documentId);
Workspace\Solution\ProjectChanges.cs (23)
18
public ProjectId ProjectId =>
NewProject
.Id;
27
foreach (var reference in
NewProject
.ProjectReferences)
38
var newRefs = new HashSet<ProjectReference>(
NewProject
.ProjectReferences);
51
foreach (var metadata in
NewProject
.MetadataReferences)
62
var newMetadata = new HashSet<MetadataReference>(
NewProject
.MetadataReferences);
75
foreach (var analyzerReference in
NewProject
.AnalyzerReferences)
86
var newAnalyzerReferences = new HashSet<AnalyzerReference>(
NewProject
.AnalyzerReferences);
97
/// Get <see cref="DocumentId"/>s of added documents in the order they appear in <see cref="Project.DocumentIds"/> of the <see cref="
NewProject
"/>.
100
=>
NewProject
.State.DocumentStates.GetAddedStateIds(OldProject.State.DocumentStates);
103
/// Get <see cref="DocumentId"/>s of added dditional documents in the order they appear in <see cref="Project.DocumentIds"/> of <see cref="
NewProject
"/>.
106
=>
NewProject
.State.AdditionalDocumentStates.GetAddedStateIds(OldProject.State.AdditionalDocumentStates);
109
/// Get <see cref="DocumentId"/>s of added analyzer config documents in the order they appear in <see cref="Project.DocumentIds"/> of <see cref="
NewProject
"/>.
112
=>
NewProject
.State.AnalyzerConfigDocumentStates.GetAddedStateIds(OldProject.State.AnalyzerConfigDocumentStates);
116
/// in the order they appear in <see cref="Project.DocumentIds"/> of <see cref="
NewProject
"/>.
122
/// Get changed documents in the order they appear in <see cref="Project.DocumentIds"/> of <see cref="
NewProject
"/>.
130
=>
NewProject
.State.DocumentStates.GetChangedStateIds(OldProject.State.DocumentStates, onlyGetDocumentsWithTextChanges, ignoreUnchangeableDocuments);
134
/// in the order they appear in <see cref="Project.DocumentIds"/> of <see cref="
NewProject
"/>.
137
=>
NewProject
.State.AdditionalDocumentStates.GetChangedStateIds(OldProject.State.AdditionalDocumentStates);
141
/// in the order they appear in <see cref="Project.DocumentIds"/> of <see cref="
NewProject
"/>.
144
=>
NewProject
.State.AnalyzerConfigDocumentStates.GetChangedStateIds(OldProject.State.AnalyzerConfigDocumentStates);
150
=>
NewProject
.State.DocumentStates.GetRemovedStateIds(OldProject.State.DocumentStates);
156
=>
NewProject
.State.AdditionalDocumentStates.GetRemovedStateIds(OldProject.State.AdditionalDocumentStates);
162
=>
NewProject
.State.AnalyzerConfigDocumentStates.GetRemovedStateIds(OldProject.State.AnalyzerConfigDocumentStates);
Workspace\Workspace.cs (21)
303
if (!projectChanges.
NewProject
.SupportsCompilation)
1535
progressTracker.Report(CodeAnalysisProgress.Description(string.Format(WorkspacesResources.Applying_changes_to_0, projectChanges.
NewProject
.Name)));
1590
var newDoc = projectChange.
NewProject
.GetRequiredDocument(docId);
1654
projectChanges.OldProject.CompilationOptions != projectChanges.
NewProject
.CompilationOptions)
1661
Contract.ThrowIfNull(projectChanges.
NewProject
.CompilationOptions);
1668
projectChanges.
NewProject
.CompilationOptions.WithSyntaxTreeOptionsProvider(
1677
if (!CanApplyCompilationOptionChange(projectChanges.OldProject.CompilationOptions, newOptionsWithoutSyntaxTreeOptionsChange, projectChanges.
NewProject
))
1685
projectChanges.OldProject.ParseOptions != projectChanges.
NewProject
.ParseOptions &&
1686
!CanApplyParseOptionChange(projectChanges.OldProject.ParseOptions!, projectChanges.
NewProject
.ParseOptions!, projectChanges.
NewProject
))
1702
&& projectChanges.GetChangedDocuments().Any(id => projectChanges.
NewProject
.GetDocument(id)!.HasInfoChanged(projectChanges.OldProject.GetDocument(id)!)))
1718
projectChanges.
NewProject
.State.DocumentStates.GetState(documentId)!;
1829
projectChanges.
NewProject
.CompilationOptions?.WithSyntaxTreeOptionsProvider(
1837
if (projectChanges.OldProject.ParseOptions != projectChanges.
NewProject
.ParseOptions)
1839
this.ApplyParseOptionsChanged(projectChanges.ProjectId, projectChanges.
NewProject
.ParseOptions!);
1899
var document = projectChanges.
NewProject
.GetDocument(documentId)!;
1908
var document = projectChanges.
NewProject
.GetAdditionalDocument(documentId)!;
1917
var document = projectChanges.
NewProject
.GetAnalyzerConfigDocument(documentId)!;
1932
var newDoc = projectChanges.
NewProject
.GetAdditionalDocument(documentId)!;
1942
var newDoc = projectChanges.
NewProject
.GetAnalyzerConfigDocument(documentId)!;
1954
var newDoc = projectChanges.
NewProject
.GetDocument(documentId)!;
Microsoft.CodeAnalysis.Workspaces.MSBuild (1)
MSBuild\MSBuildWorkspace.cs (1)
333
var project = projectChanges.OldProject ?? projectChanges.
NewProject
;
Microsoft.CodeAnalysis.Workspaces.Test.Utilities (8)
SolutionUtilities.cs (2)
36
return solutionDifferences.GetProjectChanges().Select(n => n.
NewProject
.GetChanges(n.OldProject));
102
return Tuple.Create(projectChanges.
NewProject
, projectChanges.GetAddedProjectReferences().Single());
Workspaces\TestWorkspace`1.cs (6)
467
if (projectChanges.OldProject.FilePath != projectChanges.
NewProject
.FilePath)
469
var hostProject = this.GetTestProject(projectChanges.
NewProject
.Id);
472
hostProject.OnProjectFilePathChanged(projectChanges.
NewProject
.FilePath);
473
base.OnProjectNameChanged(projectChanges.
NewProject
.Id, projectChanges.
NewProject
.Name, projectChanges.
NewProject
.FilePath);
Microsoft.VisualStudio.LanguageServices (2)
Preview\ReferenceChange.cs (1)
32
var newSolution = projectChanges.
NewProject
.Solution;
ProjectSystem\VisualStudioWorkspaceImpl.cs (1)
668
var newDocument = projectChanges.
NewProject
.GetRequiredDocument(changedDocumentId);