/// <summary>
 /// For the specified scope, get the current quota requests for a one year
 /// period ending at the time is made. Use the **oData** filter to select quota
 /// requests.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='scope'>
 /// The target Azure resource URI. For example,
 /// `/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/qms-test/providers/Microsoft.Batch/batchAccounts/testAccount/`.
 /// This is the target Azure resource URI for the List GET operation. If a
 /// `{resourceName}` is added after `/quotas`, then it's the target Azure
 /// resource URI in the GET operation for the specific resource.
 /// </param>
 /// <param name='filter'>
 /// | Field                    | Supported operators
 /// |---------------------|------------------------
 ///
 /// |requestSubmitTime | ge, le, eq, gt, lt
 /// |provisioningState eq {QuotaRequestState}
 /// |resourceName eq {resourceName}
 /// </param>
 /// <param name='top'>
 /// Number of records to return.
 /// </param>
 /// <param name='skiptoken'>
 /// The **Skiptoken** parameter is used only if a previous operation returned a
 /// partial result. If a previous response contains a **nextLink** element, its
 /// value includes a **skiptoken** parameter that specifies a starting point to
 /// use for subsequent calls.
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task <IPage <QuotaRequestDetails> > ListAsync(this IQuotaRequestStatusOperations operations, string scope, string filter = default(string), int?top = default(int?), string skiptoken = default(string), CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.ListWithHttpMessagesAsync(scope, filter, top, skiptoken, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
 /// <summary>
 /// Get the quota request details and status by quota request ID for the
 /// resources of the resource provider at a specific location. The quota
 /// request ID **id** is returned in the response of the PUT operation.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='id'>
 /// Quota request ID.
 /// </param>
 /// <param name='scope'>
 /// The target Azure resource URI. For example,
 /// `/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/qms-test/providers/Microsoft.Batch/batchAccounts/testAccount/`.
 /// This is the target Azure resource URI for the List GET operation. If a
 /// `{resourceName}` is added after `/quotas`, then it's the target Azure
 /// resource URI in the GET operation for the specific resource.
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task <QuotaRequestDetails> GetAsync(this IQuotaRequestStatusOperations operations, string id, string scope, CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.GetWithHttpMessagesAsync(id, scope, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
 /// <summary>
 /// For the specified scope, get the current quota requests for a one year
 /// period ending at the time is made. Use the **oData** filter to select quota
 /// requests.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='nextPageLink'>
 /// The NextLink from the previous successful call to List operation.
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task <IPage <QuotaRequestDetails> > ListNextAsync(this IQuotaRequestStatusOperations operations, string nextPageLink, CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.ListNextWithHttpMessagesAsync(nextPageLink, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
Exemple #4
0
 /// <summary>
 /// Initializes client properties.
 /// </summary>
 private void Initialize()
 {
     Reservation        = new ReservationOperations(this);
     ReservationOrder   = new ReservationOrderOperations(this);
     Operation          = new OperationOperations(this);
     CalculateExchange  = new CalculateExchangeOperations(this);
     Exchange           = new ExchangeOperations(this);
     Quota              = new QuotaOperations(this);
     QuotaRequestStatus = new QuotaRequestStatusOperations(this);
     BaseUri            = new System.Uri("https://management.azure.com");
     AcceptLanguage     = "en-US";
     LongRunningOperationRetryTimeout = 30;
     GenerateClientRequestId          = true;
     SerializationSettings            = new JsonSerializerSettings
     {
         Formatting            = Newtonsoft.Json.Formatting.Indented,
         DateFormatHandling    = Newtonsoft.Json.DateFormatHandling.IsoDateFormat,
         DateTimeZoneHandling  = Newtonsoft.Json.DateTimeZoneHandling.Utc,
         NullValueHandling     = Newtonsoft.Json.NullValueHandling.Ignore,
         ReferenceLoopHandling = Newtonsoft.Json.ReferenceLoopHandling.Serialize,
         ContractResolver      = new ReadOnlyJsonContractResolver(),
         Converters            = new List <JsonConverter>
         {
             new Iso8601TimeSpanConverter()
         }
     };
     SerializationSettings.Converters.Add(new TransformationJsonConverter());
     DeserializationSettings = new JsonSerializerSettings
     {
         DateFormatHandling    = Newtonsoft.Json.DateFormatHandling.IsoDateFormat,
         DateTimeZoneHandling  = Newtonsoft.Json.DateTimeZoneHandling.Utc,
         NullValueHandling     = Newtonsoft.Json.NullValueHandling.Ignore,
         ReferenceLoopHandling = Newtonsoft.Json.ReferenceLoopHandling.Serialize,
         ContractResolver      = new ReadOnlyJsonContractResolver(),
         Converters            = new List <JsonConverter>
         {
             new Iso8601TimeSpanConverter()
         }
     };
     CustomInitialize();
     DeserializationSettings.Converters.Add(new TransformationJsonConverter());
     DeserializationSettings.Converters.Add(new CloudErrorJsonConverter());
 }
 /// <summary>
 /// Get the quota request details and status by quota request ID for the
 /// resources of the resource provider at a specific location. The quota
 /// request ID **id** is returned in the response of the PUT operation.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='id'>
 /// Quota request ID.
 /// </param>
 /// <param name='scope'>
 /// The target Azure resource URI. For example,
 /// `/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/qms-test/providers/Microsoft.Batch/batchAccounts/testAccount/`.
 /// This is the target Azure resource URI for the List GET operation. If a
 /// `{resourceName}` is added after `/quotas`, then it's the target Azure
 /// resource URI in the GET operation for the specific resource.
 /// </param>
 public static QuotaRequestDetails Get(this IQuotaRequestStatusOperations operations, string id, string scope)
 {
     return(operations.GetAsync(id, scope).GetAwaiter().GetResult());
 }
 /// <summary>
 /// For the specified scope, get the current quota requests for a one year
 /// period ending at the time is made. Use the **oData** filter to select quota
 /// requests.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='nextPageLink'>
 /// The NextLink from the previous successful call to List operation.
 /// </param>
 public static IPage <QuotaRequestDetails> ListNext(this IQuotaRequestStatusOperations operations, string nextPageLink)
 {
     return(operations.ListNextAsync(nextPageLink).GetAwaiter().GetResult());
 }
 /// <summary>
 /// For the specified scope, get the current quota requests for a one year
 /// period ending at the time is made. Use the **oData** filter to select quota
 /// requests.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='scope'>
 /// The target Azure resource URI. For example,
 /// `/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/qms-test/providers/Microsoft.Batch/batchAccounts/testAccount/`.
 /// This is the target Azure resource URI for the List GET operation. If a
 /// `{resourceName}` is added after `/quotas`, then it's the target Azure
 /// resource URI in the GET operation for the specific resource.
 /// </param>
 /// <param name='filter'>
 /// | Field                    | Supported operators
 /// |---------------------|------------------------
 ///
 /// |requestSubmitTime | ge, le, eq, gt, lt
 /// |provisioningState eq {QuotaRequestState}
 /// |resourceName eq {resourceName}
 /// </param>
 /// <param name='top'>
 /// Number of records to return.
 /// </param>
 /// <param name='skiptoken'>
 /// The **Skiptoken** parameter is used only if a previous operation returned a
 /// partial result. If a previous response contains a **nextLink** element, its
 /// value includes a **skiptoken** parameter that specifies a starting point to
 /// use for subsequent calls.
 /// </param>
 public static IPage <QuotaRequestDetails> List(this IQuotaRequestStatusOperations operations, string scope, string filter = default(string), int?top = default(int?), string skiptoken = default(string))
 {
     return(operations.ListAsync(scope, filter, top, skiptoken).GetAwaiter().GetResult());
 }
 /// <summary>
 /// For the specified Azure region (location), get the details and status of
 /// the quota request by the quota request ID for the resources of the resource
 /// provider. The PUT request for the quota (service limit) returns a response
 /// with the requestId parameter.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='subscriptionId'>
 /// Azure subscription ID.
 /// </param>
 /// <param name='providerId'>
 /// Azure resource provider ID.
 /// </param>
 /// <param name='location'>
 /// Azure region.
 /// </param>
 /// <param name='id'>
 /// Quota Request ID.
 /// </param>
 public static QuotaRequestDetails Get(this IQuotaRequestStatusOperations operations, string subscriptionId, string providerId, string location, string id)
 {
     return(operations.GetAsync(subscriptionId, providerId, location, id).GetAwaiter().GetResult());
 }
 /// <summary>
 /// For the specified Azure region (location), subscription, and resource
 /// provider, get the history of the quota requests for the past year. To
 /// select specific quota requests, use the oData filter.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='subscriptionId'>
 /// Azure subscription ID.
 /// </param>
 /// <param name='providerId'>
 /// Azure resource provider ID.
 /// </param>
 /// <param name='location'>
 /// Azure region.
 /// </param>
 /// <param name='filter'>
 /// | Field | Supported operators |
 /// |---------------------|------------------------|
 /// |requestSubmitTime | ge, le, eq, gt, lt |
 /// </param>
 /// <param name='top'>
 /// Number of records to return.
 /// </param>
 /// <param name='skiptoken'>
 /// Skiptoken is only used if a previous operation returned a partial result.
 /// If a previous response contains a nextLink element, the value of the
 /// nextLink element includes a skiptoken parameter that specifies a starting
 /// point to use for subsequent calls.
 /// </param>
 public static IPage <QuotaRequestDetails> List(this IQuotaRequestStatusOperations operations, string subscriptionId, string providerId, string location, string filter = default(string), int?top = default(int?), string skiptoken = default(string))
 {
     return(operations.ListAsync(subscriptionId, providerId, location, filter, top, skiptoken).GetAwaiter().GetResult());
 }