/// <summary>
 /// Regenerate either the primary or secondary key for use with the Maps APIs.
 /// The old key will stop working immediately.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the Azure Resource Group.
 /// </param>
 /// <param name='accountName'>
 /// The name of the Maps Account.
 /// </param>
 /// <param name='keySpecification'>
 /// Which key to regenerate:  primary or secondary.
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task <MapsAccountKeys> RegenerateKeysAsync(this IAccountsOperations operations, string resourceGroupName, string accountName, MapsKeySpecification keySpecification, CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.RegenerateKeysWithHttpMessagesAsync(resourceGroupName, accountName, keySpecification, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
 /// <summary>
 /// Regenerate either the primary or secondary key for use with the Maps APIs.
 /// The old key will stop working immediately.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the Azure Resource Group.
 /// </param>
 /// <param name='accountName'>
 /// The name of the Maps Account.
 /// </param>
 /// <param name='keySpecification'>
 /// Which key to regenerate:  primary or secondary.
 /// </param>
 public static MapsAccountKeys RegenerateKeys(this IAccountsOperations operations, string resourceGroupName, string accountName, MapsKeySpecification keySpecification)
 {
     return(operations.RegenerateKeysAsync(resourceGroupName, accountName, keySpecification).GetAwaiter().GetResult());
 }