Workspace.ApplyProjectReferenceAdded(ProjectId, ProjectReference) 方法

定义

在向项目添加项目引用的过程中 TryApplyChanges(Solution) 调用此方法。

重写此方法以实现添加项目引用的功能。

protected:
 virtual void ApplyProjectReferenceAdded(Microsoft::CodeAnalysis::ProjectId ^ projectId, Microsoft::CodeAnalysis::ProjectReference ^ projectReference);
protected virtual void ApplyProjectReferenceAdded (Microsoft.CodeAnalysis.ProjectId projectId, Microsoft.CodeAnalysis.ProjectReference projectReference);
abstract member ApplyProjectReferenceAdded : Microsoft.CodeAnalysis.ProjectId * Microsoft.CodeAnalysis.ProjectReference -> unit
override this.ApplyProjectReferenceAdded : Microsoft.CodeAnalysis.ProjectId * Microsoft.CodeAnalysis.ProjectReference -> unit
Protected Overridable Sub ApplyProjectReferenceAdded (projectId As ProjectId, projectReference As ProjectReference)

参数

projectId
ProjectId
projectReference
ProjectReference

适用于