/// <summary> /// Update the schedule identified by scheduleId. (see /// http://msdn.microsoft.com/en-us/library/windowsazure/XXXXXXX.aspx /// for more information) /// </summary> /// <param name='operations'> /// Reference to the /// Microsoft.Azure.Management.Automation.IScheduleOperations. /// </param> /// <param name='automationAccount'> /// Required. The automation account name. /// </param> /// <param name='parameters'> /// Required. The parameters supplied to the update schedule operation. /// </param> /// <returns> /// A standard service response including an HTTP status code and /// request ID. /// </returns> public static Task <OperationResponse> UpdateAsync(this IScheduleOperations operations, string automationAccount, ScheduleUpdateParameters parameters) { return(operations.UpdateAsync(automationAccount, parameters, CancellationToken.None)); }
/// <summary> /// Update the schedule identified by schedule name. /// <see href="http://aka.ms/azureautomationsdk/scheduleoperations" /> /// </summary> /// <param name='operations'> /// The operations group for this extension method. /// </param> /// <param name='resourceGroupName'> /// Name of an Azure Resource group. /// </param> /// <param name='automationAccountName'> /// The name of the automation account. /// </param> /// <param name='scheduleName'> /// The schedule name. /// </param> /// <param name='parameters'> /// The parameters supplied to the update schedule operation. /// </param> public static Schedule Update(this IScheduleOperations operations, string resourceGroupName, string automationAccountName, string scheduleName, ScheduleUpdateParameters parameters) { return(operations.UpdateAsync(resourceGroupName, automationAccountName, scheduleName, parameters).GetAwaiter().GetResult()); }
/// <summary> /// Update the schedule identified by scheduleId. (see /// http://msdn.microsoft.com/en-us/library/windowsazure/XXXXXXX.aspx /// for more information) /// </summary> /// <param name='operations'> /// Reference to the /// Microsoft.Azure.Management.Automation.IScheduleOperations. /// </param> /// <param name='automationAccount'> /// Required. The automation account name. /// </param> /// <param name='parameters'> /// Required. The parameters supplied to the update schedule operation. /// </param> /// <returns> /// A standard service response including an HTTP status code and /// request ID. /// </returns> public static OperationResponse Update(this IScheduleOperations operations, string automationAccount, ScheduleUpdateParameters parameters) { return(Task.Factory.StartNew((object s) => { return ((IScheduleOperations)s).UpdateAsync(automationAccount, parameters); } , operations, CancellationToken.None, TaskCreationOptions.None, TaskScheduler.Default).Unwrap().GetAwaiter().GetResult()); }
/// <summary> /// Update the schedule identified by schedule name. /// <see href="http://aka.ms/azureautomationsdk/scheduleoperations" /> /// </summary> /// <param name='operations'> /// The operations group for this extension method. /// </param> /// <param name='resourceGroupName'> /// Name of an Azure Resource group. /// </param> /// <param name='automationAccountName'> /// The name of the automation account. /// </param> /// <param name='scheduleName'> /// The schedule name. /// </param> /// <param name='parameters'> /// The parameters supplied to the update schedule operation. /// </param> /// <param name='cancellationToken'> /// The cancellation token. /// </param> public static async Task <Schedule> UpdateAsync(this IScheduleOperations operations, string resourceGroupName, string automationAccountName, string scheduleName, ScheduleUpdateParameters parameters, CancellationToken cancellationToken = default(CancellationToken)) { using (var _result = await operations.UpdateWithHttpMessagesAsync(resourceGroupName, automationAccountName, scheduleName, parameters, null, cancellationToken).ConfigureAwait(false)) { return(_result.Body); } }