/// <summary> /// Get the Global policy definition 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='cancellationToken'> /// The cancellation token. /// </param> public static async Task <PolicyContract> GetAsync(this IPolicyOperations operations, string resourceGroupName, string serviceName, CancellationToken cancellationToken = default(CancellationToken)) { using (var _result = await operations.GetWithHttpMessagesAsync(resourceGroupName, serviceName, null, cancellationToken).ConfigureAwait(false)) { return(_result.Body); } }
/// <summary> /// Retrieves the current policy for a given kind of TEE. /// </summary> /// <param name='operations'> /// The operations group for this extension method. /// </param> /// <param name='tenantBaseUrl'> /// The tenant name, for example https://mytenant.attest.azure.net. /// </param> /// <param name='tee'> /// Specifies the trusted execution environment to be used to validate the /// evidence. Possible values include: 'SgxEnclave', 'OpenEnclave', /// 'CyResComponent', 'AzureGuest' /// </param> /// <param name='cancellationToken'> /// The cancellation token. /// </param> public static async Task <object> GetAsync(this IPolicyOperations operations, string tenantBaseUrl, string tee, CancellationToken cancellationToken = default(CancellationToken)) { using (var _result = await operations.GetWithHttpMessagesAsync(tenantBaseUrl, tee, null, cancellationToken).ConfigureAwait(false)) { return(_result.Body); } }