IVsProjectStartupServices Interface

Definition

Enables project extensibility by other developers.

public interface class IVsProjectStartupServices
public interface class IVsProjectStartupServices
__interface IVsProjectStartupServices
[System.Runtime.InteropServices.Guid("82780F79-A3ED-4B7F-90C0-5FEE14CBB53E")]
[System.Runtime.InteropServices.InterfaceType(1)]
public interface IVsProjectStartupServices
[System.Runtime.InteropServices.Guid("82780F79-A3ED-4B7F-90C0-5FEE14CBB53E")]
[System.Runtime.InteropServices.InterfaceType(System.Runtime.InteropServices.ComInterfaceType.InterfaceIsIUnknown)]
public interface IVsProjectStartupServices
[<System.Runtime.InteropServices.Guid("82780F79-A3ED-4B7F-90C0-5FEE14CBB53E")>]
[<System.Runtime.InteropServices.InterfaceType(1)>]
type IVsProjectStartupServices = interface
[<System.Runtime.InteropServices.Guid("82780F79-A3ED-4B7F-90C0-5FEE14CBB53E")>]
[<System.Runtime.InteropServices.InterfaceType(System.Runtime.InteropServices.ComInterfaceType.InterfaceIsIUnknown)>]
type IVsProjectStartupServices = interface
Public Interface IVsProjectStartupServices
Attributes

Remarks

IVsProjectStartupServices is an optional interface that allows a third party VSPackage to register a service GUID that your project persists into your project file so that every time your project loads, you load that information into your project file and QueryService for that GUID. This allows a third party VSPackage to be delay loaded at the point that your project is loaded again. In this way, the third party VSPackage avoids using the now obsolete Preload=1 option formerly in the registry. However the VSPackage continues to assure that it is loaded at the time your project is loaded.

Your project need only call QueryService passing it the parameters (guidService, IID_IUnknown, &punk); it makes no attempt to call a method on the service. The VSPackage upon being loaded can then enumerate the loaded projects and perform appropriate operations (for example, hook up to project events).

The IVsProjectStartupServices interface can be retrieved from a project hierarchy in the following manner:

GetProperty(IVsProjectStartupServices, IVsProjectStartupServices...)

IVsProjectStartupServices is used primarily for extensibility if you are creating a project type that is extensible by other developers.

Notes to Implementers

Implemented on the IVsHierarchy to make your project extensible by other developers.

Methods

AddStartupService(Guid)

Adds third party service to the list of services to be started when the project is instantiated and ensures that all third party services are started.

GetStartupServiceEnum(IEnumProjectStartupServices)

Used to look up a third party service array element by GUID.

RemoveStartupService(Guid)

Removes a service ID GUID from the list of third party services to be started and releases the service if it has been loaded.

Applies to