Share via


Solution.WithProjectMetadataReferences メソッド

定義

指定したメタデータ参照のみを含むようにプロジェクトを更新して、新しいソリューション インスタンスを作成します。

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

パラメーター

projectId
ProjectId
metadataReferences
IEnumerable<MetadataReference>

戻り値

例外

metadataReferences には、null が含まれます。

metadataReferences には重複する項目が含まれています。

ソリューションに含 projectIdまれていない .

適用対象