Пример #1
0
 /// <summary>
 /// Updates an existing quota counter value in the specified service instance.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group.
 /// </param>
 /// <param name='serviceName'>
 /// The name of the API Management service.
 /// </param>
 /// <param name='quotaCounterKey'>
 /// Quota counter key identifier.This is the result of expression defined in
 /// counter-key attribute of the quota-by-key policy.For Example, if you
 /// specify counter-key="boo" in the policy, then it’s accessible by "boo"
 /// counter key. But if it’s defined as counter-key="@("b"+"a")" then it will
 /// be accessible by "ba" key
 /// </param>
 /// <param name='quotaPeriodKey'>
 /// Quota period key identifier.
 /// </param>
 /// <param name='parameters'>
 /// The value of the Quota counter to be applied on the specified period.
 /// </param>
 public static void Update(this IQuotaByPeriodKeysOperations operations, string resourceGroupName, string serviceName, string quotaCounterKey, string quotaPeriodKey, QuotaCounterValueContractProperties parameters)
 {
     operations.UpdateAsync(resourceGroupName, serviceName, quotaCounterKey, quotaPeriodKey, parameters).GetAwaiter().GetResult();
 }
Пример #2
0
 /// <summary>
 /// Updates an existing quota counter value in the specified service instance.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group.
 /// </param>
 /// <param name='serviceName'>
 /// The name of the API Management service.
 /// </param>
 /// <param name='quotaCounterKey'>
 /// Quota counter key identifier.This is the result of expression defined in
 /// counter-key attribute of the quota-by-key policy.For Example, if you
 /// specify counter-key="boo" in the policy, then it’s accessible by "boo"
 /// counter key. But if it’s defined as counter-key="@("b"+"a")" then it will
 /// be accessible by "ba" key
 /// </param>
 /// <param name='quotaPeriodKey'>
 /// Quota period key identifier.
 /// </param>
 /// <param name='parameters'>
 /// The value of the Quota counter to be applied on the specified period.
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task UpdateAsync(this IQuotaByPeriodKeysOperations operations, string resourceGroupName, string serviceName, string quotaCounterKey, string quotaPeriodKey, QuotaCounterValueContractProperties parameters, CancellationToken cancellationToken = default(CancellationToken))
 {
     (await operations.UpdateWithHttpMessagesAsync(resourceGroupName, serviceName, quotaCounterKey, quotaPeriodKey, parameters, null, cancellationToken).ConfigureAwait(false)).Dispose();
 }
 /// <summary>
 /// Updates an existing quota counter value in the specified service instance.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group.
 /// </param>
 /// <param name='serviceName'>
 /// The name of the API Management service.
 /// </param>
 /// <param name='quotaCounterKey'>
 /// Quota counter key identifier.This is the result of expression defined in
 /// counter-key attribute of the quota-by-key policy.For Example, if you
 /// specify counter-key="boo" in the policy, then it’s accessible by "boo"
 /// counter key. But if it’s defined as counter-key="@("b"+"a")" then it will
 /// be accessible by "ba" key
 /// </param>
 /// <param name='quotaPeriodKey'>
 /// Quota period key identifier.
 /// </param>
 /// <param name='parameters'>
 /// The value of the Quota counter to be applied on the specified period.
 /// </param>
 public static QuotaCounterContract Update(this IQuotaByPeriodKeysOperations operations, string resourceGroupName, string serviceName, string quotaCounterKey, string quotaPeriodKey, QuotaCounterValueUpdateContract parameters)
 {
     return(operations.UpdateAsync(resourceGroupName, serviceName, quotaCounterKey, quotaPeriodKey, parameters).GetAwaiter().GetResult());
 }