Ejemplo n.º 1
0
 /// <summary>
 /// Lists all the Global Policy definitions of the Api Management service.
 /// </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='scope'>
 /// Policy scope. Possible values include: 'Tenant', 'Product', 'Api',
 /// 'Operation', 'All'
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task <PolicyCollection> ListByServiceAsync(this IPolicyOperations operations, string resourceGroupName, string serviceName, PolicyScopeContract?scope = default(PolicyScopeContract?), CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.ListByServiceWithHttpMessagesAsync(resourceGroupName, serviceName, scope, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }