Beispiel #1
0
 /// <summary>
 /// Get a single billing subscription by name.
 /// <see href="https://docs.microsoft.com/en-us/rest/api/consumption/" />
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='billingAccountName'>
 /// billing Account Id.
 /// </param>
 /// <param name='invoiceSectionName'>
 /// InvoiceSection Id.
 /// </param>
 /// <param name='billingSubscriptionName'>
 /// Billing Subscription Id.
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task <BillingSubscriptionSummary> GetAsync(this IBillingSubscriptionOperations operations, string billingAccountName, string invoiceSectionName, string billingSubscriptionName, CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.GetWithHttpMessagesAsync(billingAccountName, invoiceSectionName, billingSubscriptionName, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
Beispiel #2
0
 /// <summary>
 /// Transfers the GTM subscription from one invoice section to another within a
 /// billing account.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='billingAccountName'>
 /// billing Account Id.
 /// </param>
 /// <param name='invoiceSectionName'>
 /// InvoiceSection Id.
 /// </param>
 /// <param name='billingSubscriptionName'>
 /// Billing Subscription Id.
 /// </param>
 /// <param name='parameters'>
 /// Parameters supplied to the Transfer Billing Subscription operation.
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task <TransferBillingSubscriptionResult> TransferAsync(this IBillingSubscriptionOperations operations, string billingAccountName, string invoiceSectionName, string billingSubscriptionName, TransferBillingSubscriptionRequestProperties parameters, CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.TransferWithHttpMessagesAsync(billingAccountName, invoiceSectionName, billingSubscriptionName, parameters, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
Beispiel #3
0
 /// <summary>
 /// Transfers the GTM subscription from one invoice section to another within a
 /// billing account.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='billingAccountName'>
 /// billing Account Id.
 /// </param>
 /// <param name='invoiceSectionName'>
 /// InvoiceSection Id.
 /// </param>
 /// <param name='billingSubscriptionName'>
 /// Billing Subscription Id.
 /// </param>
 /// <param name='parameters'>
 /// Parameters supplied to the Transfer Billing Subscription operation.
 /// </param>
 public static TransferBillingSubscriptionResult Transfer(this IBillingSubscriptionOperations operations, string billingAccountName, string invoiceSectionName, string billingSubscriptionName, TransferBillingSubscriptionRequestProperties parameters)
 {
     return(operations.TransferAsync(billingAccountName, invoiceSectionName, billingSubscriptionName, parameters).GetAwaiter().GetResult());
 }
Beispiel #4
0
 /// <summary>
 /// Get a single billing subscription by name.
 /// <see href="https://docs.microsoft.com/en-us/rest/api/consumption/" />
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='billingAccountName'>
 /// billing Account Id.
 /// </param>
 /// <param name='invoiceSectionName'>
 /// InvoiceSection Id.
 /// </param>
 /// <param name='billingSubscriptionName'>
 /// Billing Subscription Id.
 /// </param>
 public static BillingSubscriptionSummary Get(this IBillingSubscriptionOperations operations, string billingAccountName, string invoiceSectionName, string billingSubscriptionName)
 {
     return(operations.GetAsync(billingAccountName, invoiceSectionName, billingSubscriptionName).GetAwaiter().GetResult());
 }