IDeploymentContext Interface
Represents the context of a deployment step that is being executed while a SharePoint project is being deployed or retracted.
Namespace: Microsoft.VisualStudio.SharePoint.Deployment
Assembly: Microsoft.VisualStudio.SharePoint (in Microsoft.VisualStudio.SharePoint.dll)
Syntax
'Declaration
Public Interface IDeploymentContext _
Inherits IAnnotatedObject
public interface IDeploymentContext : IAnnotatedObject
The IDeploymentContext type exposes the following members.
Properties
Name | Description | |
---|---|---|
Annotations | Gets an instance IAnnotationDictionary to associate custom data with the object implementing the IAnnotatedObject interface. (Inherited from IAnnotatedObject.) | |
IsCanceled | Gets whether the deployment was canceled by the user. | |
IsDeploying | Gets whether the project is being deployed. | |
IsRetracting | Gets whether the project is being retracted. | |
Logger | Gets the access to the project logger. | |
Project | Gets the access to the current project that is being deployed or retracted. | |
StartMode | Gets the access to the start mode the reason why deployment was initiated. |
Top
Methods
Name | Description | |
---|---|---|
SiteCollectionUrl | Returns the canonical URL of the Microsoft.SharePoint.SPSite that the project is connected to, according to SharePoint. | |
SiteUrl | Returns the canonical URL of the Microsoft.SharePoint.SPWeb that the project is connected to, according to SharePoint. | |
WebApplicationUrl | Returns the root URL of the SPWebApplication. |
Top
Remarks
Visual Studio passes IDeploymentContext to the CanExecute and Execute methods of deployment steps. A new deployment context is initialized at the start of a deployment and retraction operation.
The IDeploymentContext interface implements the IAnnotatedObject to enable deployment steps to store and pass data between steps.