コマンドライン引数とその値の辞書を取得します。 SSDT でビルドする際、.sqlproj ファイルまたは参照先の .targets ファイル内に引数がある場合はその引数を使用できます。 たとえば、"true" という値の "RunMyContributor" 引数を追加するには、次のように追加します。
<PropertyGroup> <ContributorArguments Condition="'$(Configuration)' == 'Debug''"> $(ContributorArguments);RunMyContributor=True; </ContributorArguments> </PropertyGroup>
この場合、引数はデバッグ構成のためだけに追加されます。 上記の構成を使用すると、MSBuild 環境から情報を収集してコントリビューターに渡すことができます。
名前空間: Microsoft.SqlServer.Dac.Deployment
アセンブリ: Microsoft.SqlServer.Dac.Extensions (Microsoft.SqlServer.Dac.Extensions.dll)
構文
'宣言
Public ReadOnly Property Arguments As IDictionary(Of String, String)
Get
'使用
Dim instance As BuildContributorContext
Dim value As IDictionary(Of String, String)
value = instance.Arguments
public IDictionary<string, string> Arguments { get; }
public:
property IDictionary<String^, String^>^ Arguments {
IDictionary<String^, String^>^ get ();
}
member Arguments : IDictionary<string, string>
function get Arguments () : IDictionary<String, String>
プロパティ値
型: System.Collections.Generic.IDictionary<String, String>