|
| 1 | +// <auto-generated> |
| 2 | +// Copyright (c) Microsoft Corporation. All rights reserved. |
| 3 | +// Licensed under the MIT License. See License.txt in the project root for |
| 4 | +// license information. |
| 5 | +// |
| 6 | +// Code generated by Microsoft (R) AutoRest Code Generator. |
| 7 | +// Changes may cause incorrect behavior and will be lost if the code is |
| 8 | +// regenerated. |
| 9 | +// </auto-generated> |
| 10 | + |
| 11 | +namespace Microsoft.Azure.Management.Internal.Network.Version2017_10_01 |
| 12 | +{ |
| 13 | + using Microsoft.Rest; |
| 14 | + using Microsoft.Rest.Azure; |
| 15 | + using Models; |
| 16 | + using System.Threading; |
| 17 | + using System.Threading.Tasks; |
| 18 | + |
| 19 | + /// <summary> |
| 20 | + /// Extension methods for AvailableEndpointServicesOperations. |
| 21 | + /// </summary> |
| 22 | + public static partial class AvailableEndpointServicesOperationsExtensions |
| 23 | + { |
| 24 | + /// <summary> |
| 25 | + /// List what values of endpoint services are available for use. |
| 26 | + /// </summary> |
| 27 | + /// <param name='operations'> |
| 28 | + /// The operations group for this extension method. |
| 29 | + /// </param> |
| 30 | + /// <param name='location'> |
| 31 | + /// The location to check available endpoint services. |
| 32 | + /// </param> |
| 33 | + public static IPage<EndpointServiceResult> List(this IAvailableEndpointServicesOperations operations, string location) |
| 34 | + { |
| 35 | + return operations.ListAsync(location).GetAwaiter().GetResult(); |
| 36 | + } |
| 37 | + |
| 38 | + /// <summary> |
| 39 | + /// List what values of endpoint services are available for use. |
| 40 | + /// </summary> |
| 41 | + /// <param name='operations'> |
| 42 | + /// The operations group for this extension method. |
| 43 | + /// </param> |
| 44 | + /// <param name='location'> |
| 45 | + /// The location to check available endpoint services. |
| 46 | + /// </param> |
| 47 | + /// <param name='cancellationToken'> |
| 48 | + /// The cancellation token. |
| 49 | + /// </param> |
| 50 | + public static async Task<IPage<EndpointServiceResult>> ListAsync(this IAvailableEndpointServicesOperations operations, string location, CancellationToken cancellationToken = default(CancellationToken)) |
| 51 | + { |
| 52 | + using (var _result = await operations.ListWithHttpMessagesAsync(location, null, cancellationToken).ConfigureAwait(false)) |
| 53 | + { |
| 54 | + return _result.Body; |
| 55 | + } |
| 56 | + } |
| 57 | + |
| 58 | + /// <summary> |
| 59 | + /// List what values of endpoint services are available for use. |
| 60 | + /// </summary> |
| 61 | + /// <param name='operations'> |
| 62 | + /// The operations group for this extension method. |
| 63 | + /// </param> |
| 64 | + /// <param name='nextPageLink'> |
| 65 | + /// The NextLink from the previous successful call to List operation. |
| 66 | + /// </param> |
| 67 | + public static IPage<EndpointServiceResult> ListNext(this IAvailableEndpointServicesOperations operations, string nextPageLink) |
| 68 | + { |
| 69 | + return operations.ListNextAsync(nextPageLink).GetAwaiter().GetResult(); |
| 70 | + } |
| 71 | + |
| 72 | + /// <summary> |
| 73 | + /// List what values of endpoint services are available for use. |
| 74 | + /// </summary> |
| 75 | + /// <param name='operations'> |
| 76 | + /// The operations group for this extension method. |
| 77 | + /// </param> |
| 78 | + /// <param name='nextPageLink'> |
| 79 | + /// The NextLink from the previous successful call to List operation. |
| 80 | + /// </param> |
| 81 | + /// <param name='cancellationToken'> |
| 82 | + /// The cancellation token. |
| 83 | + /// </param> |
| 84 | + public static async Task<IPage<EndpointServiceResult>> ListNextAsync(this IAvailableEndpointServicesOperations operations, string nextPageLink, CancellationToken cancellationToken = default(CancellationToken)) |
| 85 | + { |
| 86 | + using (var _result = await operations.ListNextWithHttpMessagesAsync(nextPageLink, null, cancellationToken).ConfigureAwait(false)) |
| 87 | + { |
| 88 | + return _result.Body; |
| 89 | + } |
| 90 | + } |
| 91 | + |
| 92 | + } |
| 93 | +} |
0 commit comments