Example #1
0
 /// <summary>
 /// Get assigned Gateway Certificate Authority details.
 /// </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='gatewayId'>
 /// Gateway entity identifier. Must be unique in the current API Management
 /// service instance. Must not have value 'managed'
 /// </param>
 /// <param name='certificateId'>
 /// Identifier of the certificate entity. Must be unique in the current API
 /// Management service instance.
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task <GatewayCertificateAuthorityContract> GetAsync(this IGatewayCertificateAuthorityOperations operations, string resourceGroupName, string serviceName, string gatewayId, string certificateId, CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.GetWithHttpMessagesAsync(resourceGroupName, serviceName, gatewayId, certificateId, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
Example #2
0
 /// <summary>
 /// Lists the collection of Certificate Authorities for the specified Gateway
 /// entity.
 /// </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='gatewayId'>
 /// Gateway entity identifier. Must be unique in the current API Management
 /// service instance. Must not have value 'managed'
 /// </param>
 /// <param name='odataQuery'>
 /// OData parameters to apply to the operation.
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task <IPage <GatewayCertificateAuthorityContract> > ListByServiceAsync(this IGatewayCertificateAuthorityOperations operations, string resourceGroupName, string serviceName, string gatewayId, ODataQuery <GatewayCertificateAuthorityContract> odataQuery = default(ODataQuery <GatewayCertificateAuthorityContract>), CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.ListByServiceWithHttpMessagesAsync(resourceGroupName, serviceName, gatewayId, odataQuery, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
Example #3
0
 /// <summary>
 /// Lists the collection of Certificate Authorities for the specified Gateway
 /// entity.
 /// </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='gatewayId'>
 /// Gateway entity identifier. Must be unique in the current API Management
 /// service instance. Must not have value 'managed'
 /// </param>
 /// <param name='odataQuery'>
 /// OData parameters to apply to the operation.
 /// </param>
 public static IPage <GatewayCertificateAuthorityContract> ListByService(this IGatewayCertificateAuthorityOperations operations, string resourceGroupName, string serviceName, string gatewayId, ODataQuery <GatewayCertificateAuthorityContract> odataQuery = default(ODataQuery <GatewayCertificateAuthorityContract>))
 {
     return(operations.ListByServiceAsync(resourceGroupName, serviceName, gatewayId, odataQuery).GetAwaiter().GetResult());
 }
Example #4
0
 /// <summary>
 /// Lists the collection of Certificate Authorities for the specified Gateway
 /// entity.
 /// </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 <GatewayCertificateAuthorityContract> > ListByServiceNextAsync(this IGatewayCertificateAuthorityOperations operations, string nextPageLink, CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.ListByServiceNextWithHttpMessagesAsync(nextPageLink, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
Example #5
0
 /// <summary>
 /// Lists the collection of Certificate Authorities for the specified Gateway
 /// entity.
 /// </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 <GatewayCertificateAuthorityContract> ListByServiceNext(this IGatewayCertificateAuthorityOperations operations, string nextPageLink)
 {
     return(operations.ListByServiceNextAsync(nextPageLink).GetAwaiter().GetResult());
 }
Example #6
0
 /// <summary>
 /// Remove relationship between Certificate Authority and Gateway entity.
 /// </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='gatewayId'>
 /// Gateway entity identifier. Must be unique in the current API Management
 /// service instance. Must not have value 'managed'
 /// </param>
 /// <param name='certificateId'>
 /// Identifier of the certificate entity. Must be unique in the current API
 /// Management service instance.
 /// </param>
 /// <param name='ifMatch'>
 /// ETag of the Entity. ETag should match the current entity state from the
 /// header response of the GET request or it should be * for unconditional
 /// update.
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task DeleteAsync(this IGatewayCertificateAuthorityOperations operations, string resourceGroupName, string serviceName, string gatewayId, string certificateId, string ifMatch, CancellationToken cancellationToken = default(CancellationToken))
 {
     (await operations.DeleteWithHttpMessagesAsync(resourceGroupName, serviceName, gatewayId, certificateId, ifMatch, null, cancellationToken).ConfigureAwait(false)).Dispose();
 }
Example #7
0
 /// <summary>
 /// Remove relationship between Certificate Authority and Gateway entity.
 /// </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='gatewayId'>
 /// Gateway entity identifier. Must be unique in the current API Management
 /// service instance. Must not have value 'managed'
 /// </param>
 /// <param name='certificateId'>
 /// Identifier of the certificate entity. Must be unique in the current API
 /// Management service instance.
 /// </param>
 /// <param name='ifMatch'>
 /// ETag of the Entity. ETag should match the current entity state from the
 /// header response of the GET request or it should be * for unconditional
 /// update.
 /// </param>
 public static void Delete(this IGatewayCertificateAuthorityOperations operations, string resourceGroupName, string serviceName, string gatewayId, string certificateId, string ifMatch)
 {
     operations.DeleteAsync(resourceGroupName, serviceName, gatewayId, certificateId, ifMatch).GetAwaiter().GetResult();
 }
Example #8
0
 /// <summary>
 /// Assign Certificate entity to Gateway entity as Certificate Authority.
 /// </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='gatewayId'>
 /// Gateway entity identifier. Must be unique in the current API Management
 /// service instance. Must not have value 'managed'
 /// </param>
 /// <param name='certificateId'>
 /// Identifier of the certificate entity. Must be unique in the current API
 /// Management service instance.
 /// </param>
 /// <param name='parameters'>
 /// </param>
 /// <param name='ifMatch'>
 /// ETag of the Entity. Not required when creating an entity, but required when
 /// updating an entity.
 /// </param>
 public static GatewayCertificateAuthorityContract CreateOrUpdate(this IGatewayCertificateAuthorityOperations operations, string resourceGroupName, string serviceName, string gatewayId, string certificateId, GatewayCertificateAuthorityContract parameters, string ifMatch = default(string))
 {
     return(operations.CreateOrUpdateAsync(resourceGroupName, serviceName, gatewayId, certificateId, parameters, ifMatch).GetAwaiter().GetResult());
 }
Example #9
0
 /// <summary>
 /// Get assigned Gateway Certificate Authority details.
 /// </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='gatewayId'>
 /// Gateway entity identifier. Must be unique in the current API Management
 /// service instance. Must not have value 'managed'
 /// </param>
 /// <param name='certificateId'>
 /// Identifier of the certificate entity. Must be unique in the current API
 /// Management service instance.
 /// </param>
 public static GatewayCertificateAuthorityContract Get(this IGatewayCertificateAuthorityOperations operations, string resourceGroupName, string serviceName, string gatewayId, string certificateId)
 {
     return(operations.GetAsync(resourceGroupName, serviceName, gatewayId, certificateId).GetAwaiter().GetResult());
 }