Partager via


Classe ContributorArgumentConfiguration

Instances of this class are created by Build and Deployment contributors during design-time to initialize arguments that are passed to them at runtime. In SSDT, these arguments must be specified using a ContributorArguments property in a .sqlproj file or a referenced .targets file. For instance to add a "RunMyContributor" argument with a value of "true", the following would be added:

<PropertyGroup> <ContributorArguments Condition="'$(Configuration)' == 'Debug''"> $(ContributorArguments);RunMyContributor=True; </ContributorArguments> </PropertyGroup>

In this case the argument is only added for Debug configuration. Using the above configuration it is possible to collect information from the MSBuild environment and pass it to the contributor. It is also possible to specify these when creating a package by using BuildPackage(String, TSqlModel, PackageMetadata, PackageOptions) and specifying PackageOptions.

Hiérarchie d'héritage

System.Object
  Microsoft.SqlServer.Dac.Deployment.ContributorArgumentConfiguration

Espace de noms :  Microsoft.SqlServer.Dac.Deployment
Assembly :  Microsoft.SqlServer.Dac.Extensions (en Microsoft.SqlServer.Dac.Extensions.dll)

Syntaxe

'Déclaration
Public NotInheritable Class ContributorArgumentConfiguration
'Utilisation
Dim instance As ContributorArgumentConfiguration
public sealed class ContributorArgumentConfiguration
public ref class ContributorArgumentConfiguration sealed
[<SealedAttribute>]
type ContributorArgumentConfiguration =  class end
public final class ContributorArgumentConfiguration

Le type ContributorArgumentConfiguration expose les membres suivants.

Constructeurs

  Nom Description
Méthode publique ContributorArgumentConfiguration() Initializes a new instance of the ContributorArgumentConfiguration class.
Méthode publique ContributorArgumentConfiguration(String, String) Initializes a new instance of the ContributorArgumentConfiguration class.

Haut de la page

Propriétés

  Nom Description
Propriété publique Name Gets or sets the name of the argument.
Propriété publique Value Gets or sets the value of the argument expressed as a string.

Haut de la page

Méthodes

  Nom Description
Méthode publique Equals (hérité de Object.)
Méthode publique GetHashCode (hérité de Object.)
Méthode publique GetType (hérité de Object.)
Méthode publique ToString (hérité de Object.)

Haut de la page

Sécurité des threads

Tous les membres publics static (Shared dans Visual Basic) de ce type sont thread-safe. Tous les membres de l'instance ne sont pas garantis comme étant thread-safe.

Voir aussi

Référence

Espace de noms Microsoft.SqlServer.Dac.Deployment