Share via


ProvideMSBuildTargetsAttribute Třída

Definice

Tento atribut zaregistruje vlastní soubory .targets do seznamu cílů známých a důvěryhodných nástrojem MSBuild.

Vytvořené položky registru: [%RegistryRoot%\MSBuild\SafeImports] "TargetsLabel"="PathToTheTargetsFile"

public ref class ProvideMSBuildTargetsAttribute sealed : Microsoft::VisualStudio::Shell::RegistrationAttribute
public ref class ProvideMSBuildTargetsAttribute sealed : Microsoft::VisualStudio::Shell::RegistrationAttribute
[System.AttributeUsage(System.AttributeTargets.Class, AllowMultiple=true, Inherited=true)]
public sealed class ProvideMSBuildTargetsAttribute : Microsoft.VisualStudio.Shell.RegistrationAttribute
[<System.AttributeUsage(System.AttributeTargets.Class, AllowMultiple=true, Inherited=true)>]
type ProvideMSBuildTargetsAttribute = class
    inherit RegistrationAttribute
Public NotInheritable Class ProvideMSBuildTargetsAttribute
Inherits RegistrationAttribute
Dědičnost
ProvideMSBuildTargetsAttribute
Atributy

Konstruktory

ProvideMSBuildTargetsAttribute(String, String)

Vytvoří nový atribut ProvideMSBuildTargets pro registraci souboru cílů do seznamu bezpečných importů nástroje MSBuild.

Vlastnosti

TypeId

Přepište vlastnost TypeID, aby odvozené třídy RegistrationAttribute fungovaly se System.ComponentModel.TypeDescriptor.GetAttributes(...). Atribut odvozený z tohoto atributu bude muset přepsat tuto vlastnost pouze v případě, že potřebuje lepší kontrolu nad instancemi, které lze použít na třídu.

(Zděděno od RegistrationAttribute)

Metody

GetPackageRegKeyPath(Guid)

Získá cestu registru (vzhledem ke kořenovému adresáři registru aplikace) VSPackage.

(Zděděno od RegistrationAttribute)
Register(RegistrationAttribute+RegistrationContext)

Volána pro registraci tohoto atributu s daným kontextem. Kontext obsahuje umístění, kam se mají umístit registrační informace. Obsahuje také další informace, jako je zaregistrovaný typ a informace o cestě.

Unregister(RegistrationAttribute+RegistrationContext)

Zrušte registraci této přípony souboru.

Platí pro