PackageRegistrationAttribute Class

 

Modify your class that implements IVsPackage by using this attribute so that the registration tool, RegPkg.exe, will look for additional attributes. For more information, see Registering VSPackages.

Namespace:   Microsoft.VisualStudio.Shell
Assembly:  Microsoft.VisualStudio.Shell.14.0 (in Microsoft.VisualStudio.Shell.14.0.dll)

System.Object
  System.Attribute
    Microsoft.VisualStudio.Shell.RegistrationAttribute
      Microsoft.VisualStudio.Shell.PackageRegistrationAttribute

[AttributeUsageAttribute(AttributeTargets.Class, Inherited = true, 
	AllowMultiple = false)]
public sealed class PackageRegistrationAttribute : RegistrationAttribute

NameDescription
System_CAPS_pubmethodPackageRegistrationAttribute()

Initializes an instance of this attribute.

NameDescription
System_CAPS_pubpropertyAllowsBackgroundLoading

Determines whether the package is safe to load on a background thread.

System_CAPS_pubpropertyRegisterUsing

Gets or sets the method of registration.

System_CAPS_pubpropertySatellitePath

Gets or sets the non-default resource .dll location.

System_CAPS_pubpropertyTypeId

Gets the current instance of this attribute.(Inherited from RegistrationAttribute.)

System_CAPS_pubpropertyUseManagedResourcesOnly

Gets or sets whether package resources are described in a managed package or in a satellite UI .dll file.

NameDescription
System_CAPS_pubmethodEquals(Object)

(Inherited from Attribute.)

System_CAPS_pubmethodGetHashCode()

(Inherited from Attribute.)

System_CAPS_pubmethodGetType()

(Inherited from Object.)

System_CAPS_pubmethodIsDefaultAttribute()

(Inherited from Attribute.)

System_CAPS_pubmethodMatch(Object)

(Inherited from Attribute.)

System_CAPS_pubmethodRegister(RegistrationAttribute.RegistrationContext)

Creates registry entries that correspond to the value of this attribute.(Overrides RegistrationAttribute.Register(RegistrationAttribute.RegistrationContext).)

System_CAPS_pubmethodToString()

(Inherited from Object.)

System_CAPS_pubmethodUnregister(RegistrationAttribute.RegistrationContext)

Removes attribute-specific registry entries.(Overrides RegistrationAttribute.Unregister(RegistrationAttribute.RegistrationContext).)

RegPkg.exe uses C# reflection to determine the attributes that modify your assembly-implemented package. RegPkg.exe then evaluates each attribute by using information that is specific to the current installation, and then creates registry entries that describe the package to Visual Studio. If your class inherits from the Managed Package Framework (MPF) class Package, this attribute is already included. If you create your own class that implements IVsPackage, manually modify your class by using one PackageRegistrationAttribute or the package will not load.

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.

Return to top
Show: