다음을 통해 공유


Solution.AddMetadataReferences 메서드

정의

지정된 메타데이터 참조를 포함하도록 업데이트된 프로젝트를 사용하여 새 솔루션 인스턴스를 만듭니다.

public:
 Microsoft::CodeAnalysis::Solution ^ AddMetadataReferences(Microsoft::CodeAnalysis::ProjectId ^ projectId, System::Collections::Generic::IEnumerable<Microsoft::CodeAnalysis::MetadataReference ^> ^ metadataReferences);
public Microsoft.CodeAnalysis.Solution AddMetadataReferences (Microsoft.CodeAnalysis.ProjectId projectId, System.Collections.Generic.IEnumerable<Microsoft.CodeAnalysis.MetadataReference> metadataReferences);
member this.AddMetadataReferences : Microsoft.CodeAnalysis.ProjectId * seq<Microsoft.CodeAnalysis.MetadataReference> -> Microsoft.CodeAnalysis.Solution
Public Function AddMetadataReferences (projectId As ProjectId, metadataReferences As IEnumerable(Of MetadataReference)) As Solution

매개 변수

projectId
ProjectId
metadataReferences
IEnumerable<MetadataReference>

반환

예외

metadataReferences에는 null가 포함됩니다.

metadataReferences 에는 중복 항목이 포함되어 있습니다.

프로젝트에 지정된 참조가 이미 포함되어 있습니다.

적용 대상