/// <summary> /// Trigger adhoc backup /// </summary> /// <param name='operations'> /// The operations group for this extension method. /// </param> /// <param name='vaultName'> /// The name of the backup vault. /// </param> /// <param name='resourceGroupName'> /// The name of the resource group where the backup vault is present. /// </param> /// <param name='backupInstanceName'> /// The name of the backup instance /// </param> /// <param name='backupRuleOptions'> /// Name for the Rule of the Policy which needs to be applied for this backup /// </param> /// <param name='cancellationToken'> /// The cancellation token. /// </param> public static async Task <OperationJobExtendedInfo> BeginAdhocBackupAsync(this IBackupInstancesOperations operations, string vaultName, string resourceGroupName, string backupInstanceName, AdHocBackupRuleOptions backupRuleOptions, CancellationToken cancellationToken = default(CancellationToken)) { using (var _result = await operations.BeginAdhocBackupWithHttpMessagesAsync(vaultName, resourceGroupName, backupInstanceName, backupRuleOptions, null, cancellationToken).ConfigureAwait(false)) { return(_result.Body); } }