Class DeploymentBase
The base class for deployments.
Inheritance
Implements
Inherited Members
Namespace: Phoenix.Applications.Deployment
Assembly: Phoenix.Abstractions.Applications.dll
Syntax
public abstract class DeploymentBase : IDisposable
Constructors
View SourceDeploymentBase(IDevice, DeploymentFactoryBase, ParameterInfo[])
Initializes a new instance of the DeploymentBase class.
Declaration
public DeploymentBase(IDevice device, DeploymentFactoryBase factory, ParameterInfo[] deploymentParameters)
Parameters
Type | Name | Description |
---|---|---|
IDevice | device | The device targeted for the deployment. |
DeploymentFactoryBase | factory | The factory used to create the deployment. |
ParameterInfo[] | deploymentParameters | The parameters corresponding to this deployment. |
Properties
View SourceCanCancel
Gets a value indicating whether or not the deployment can be canceled.
Declaration
public bool CanCancel { get; }
Property Value
Type | Description |
---|---|
System.Boolean |
CancelTokenSource
Gets the cancellation token source.
Declaration
protected CancellationTokenSource CancelTokenSource { get; }
Property Value
Type | Description |
---|---|
System.Threading.CancellationTokenSource |
CanReportProgress
Gets a value indicating whether or the deployment reports progress.
Declaration
public bool CanReportProgress { get; }
Property Value
Type | Description |
---|---|
System.Boolean |
Device
Gets the device the deployment is for.
Declaration
public IDevice Device { get; }
Property Value
Type | Description |
---|---|
IDevice |
DisplayName
Gets the display name for the deployment.
Declaration
public abstract string DisplayName { get; }
Property Value
Type | Description |
---|---|
System.String |
Factory
Gets the factory that created this deployment instance.
Declaration
public DeploymentFactoryBase Factory { get; }
Property Value
Type | Description |
---|---|
DeploymentFactoryBase |
Parameters
Gets the parameters for this deployment.
Declaration
public ReadOnlyCollection<ParameterInfo> Parameters { get; }
Property Value
Type | Description |
---|---|
System.Collections.ObjectModel.ReadOnlyCollection<ParameterInfo> |
Methods
View SourceCancel()
Cancels the deployment.
Declaration
public void Cancel()
Dispose()
Disposes the cancellation token.
Declaration
public virtual void Dispose()
StartDeployment(IProgress<DeploymentProgressInfo>)
Calls into the derived class to start a deployment.
Declaration
public async Task<bool> StartDeployment(IProgress<DeploymentProgressInfo> reportProgress)
Parameters
Type | Name | Description |
---|---|---|
System.IProgress<DeploymentProgressInfo> | reportProgress | The callback to report progress. |
Returns
Type | Description |
---|---|
System.Threading.Tasks.Task<System.Boolean> | A task that runs the deployment, returning whether or not it was successful. |
StartDeploymentInternal(IProgress<DeploymentProgressInfo>, CancellationToken)
Starts the deployment.
Declaration
protected abstract Task<bool> StartDeploymentInternal(IProgress<DeploymentProgressInfo> reportProgress, CancellationToken token)
Parameters
Type | Name | Description |
---|---|---|
System.IProgress<DeploymentProgressInfo> | reportProgress | the callback for reporting progress. |
System.Threading.CancellationToken | token | the cancellation token. |
Returns
Type | Description |
---|---|
System.Threading.Tasks.Task<System.Boolean> | The task for the deployment |
Events
View SourceDeploymentCanceled
The event for when a deployment is canceled.
Declaration
public event DeploymentBase.DeploymentCanceledHandler DeploymentCanceled
Event Type
Type | Description |
---|---|
DeploymentBase.DeploymentCanceledHandler |
DeploymentFinished
The event for when a deployment is finished.
Declaration
public event DeploymentBase.DeploymentFinishedHandler DeploymentFinished
Event Type
Type | Description |
---|---|
DeploymentBase.DeploymentFinishedHandler |