/// <summary>
 /// Creates or updates a Sql pool data masking rule.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group. The name is case insensitive.
 /// </param>
 /// <param name='workspaceName'>
 /// The name of the workspace
 /// </param>
 /// <param name='sqlPoolName'>
 /// SQL pool name
 /// </param>
 /// <param name='dataMaskingRuleName'>
 /// The name of the data masking rule.
 /// </param>
 /// <param name='parameters'>
 /// The required parameters for creating or updating a data masking rule.
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task <DataMaskingRule> CreateOrUpdateAsync(this IDataMaskingRulesOperations operations, string resourceGroupName, string workspaceName, string sqlPoolName, string dataMaskingRuleName, DataMaskingRule parameters, CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.CreateOrUpdateWithHttpMessagesAsync(resourceGroupName, workspaceName, sqlPoolName, dataMaskingRuleName, parameters, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
 /// <summary>
 /// Gets a list of Sql pool data masking rules.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group. The name is case insensitive.
 /// </param>
 /// <param name='workspaceName'>
 /// The name of the workspace
 /// </param>
 /// <param name='sqlPoolName'>
 /// SQL pool name
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task <IEnumerable <DataMaskingRule> > ListBySqlPoolAsync(this IDataMaskingRulesOperations operations, string resourceGroupName, string workspaceName, string sqlPoolName, CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.ListBySqlPoolWithHttpMessagesAsync(resourceGroupName, workspaceName, sqlPoolName, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
 /// <summary>
 /// Creates or updates a database data masking rule.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group that contains the resource. You can obtain
 /// this value from the Azure Resource Manager API or the portal.
 /// </param>
 /// <param name='serverName'>
 /// The name of the server.
 /// </param>
 /// <param name='databaseName'>
 /// The name of the database.
 /// </param>
 /// <param name='dataMaskingRuleName'>
 /// The name of the data masking rule.
 /// </param>
 /// <param name='parameters'>
 /// The required parameters for creating or updating a data masking rule.
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task <DataMaskingRuleInner> CreateOrUpdateAsync(this IDataMaskingRulesOperations operations, string resourceGroupName, string serverName, string databaseName, string dataMaskingRuleName, DataMaskingRuleInner parameters, CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.CreateOrUpdateWithHttpMessagesAsync(resourceGroupName, serverName, databaseName, dataMaskingRuleName, parameters, SqlManagementClient.SetJsonAcceptHeader(), cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
 /// <summary>
 /// Creates or updates a Sql pool data masking rule.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group. The name is case insensitive.
 /// </param>
 /// <param name='workspaceName'>
 /// The name of the workspace
 /// </param>
 /// <param name='sqlPoolName'>
 /// SQL pool name
 /// </param>
 /// <param name='dataMaskingRuleName'>
 /// The name of the data masking rule.
 /// </param>
 /// <param name='parameters'>
 /// The required parameters for creating or updating a data masking rule.
 /// </param>
 public static DataMaskingRule CreateOrUpdate(this IDataMaskingRulesOperations operations, string resourceGroupName, string workspaceName, string sqlPoolName, string dataMaskingRuleName, DataMaskingRule parameters)
 {
     return(operations.CreateOrUpdateAsync(resourceGroupName, workspaceName, sqlPoolName, dataMaskingRuleName, parameters).GetAwaiter().GetResult());
 }
 /// <summary>
 /// Gets a list of Sql pool data masking rules.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group. The name is case insensitive.
 /// </param>
 /// <param name='workspaceName'>
 /// The name of the workspace
 /// </param>
 /// <param name='sqlPoolName'>
 /// SQL pool name
 /// </param>
 public static IEnumerable <DataMaskingRule> ListBySqlPool(this IDataMaskingRulesOperations operations, string resourceGroupName, string workspaceName, string sqlPoolName)
 {
     return(operations.ListBySqlPoolAsync(resourceGroupName, workspaceName, sqlPoolName).GetAwaiter().GetResult());
 }
 /// <summary>
 /// Gets the specific Sql pool data masking rule.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group. The name is case insensitive.
 /// </param>
 /// <param name='workspaceName'>
 /// The name of the workspace
 /// </param>
 /// <param name='sqlPoolName'>
 /// SQL pool name
 /// </param>
 /// <param name='dataMaskingRuleName'>
 /// The name of the data masking rule.
 /// </param>
 public static DataMaskingRule Get(this IDataMaskingRulesOperations operations, string resourceGroupName, string workspaceName, string sqlPoolName, string dataMaskingRuleName)
 {
     return(operations.GetAsync(resourceGroupName, workspaceName, sqlPoolName, dataMaskingRuleName).GetAwaiter().GetResult());
 }
 /// <summary>
 /// Gets a list of database data masking rules.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group that contains the resource. You can obtain
 /// this value from the Azure Resource Manager API or the portal.
 /// </param>
 /// <param name='serverName'>
 /// The name of the server.
 /// </param>
 /// <param name='databaseName'>
 /// The name of the database.
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task <IEnumerable <DataMaskingRuleInner> > ListByDatabaseAsync(this IDataMaskingRulesOperations operations, string resourceGroupName, string serverName, string databaseName, CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.ListByDatabaseWithHttpMessagesAsync(resourceGroupName, serverName, databaseName, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
Example #8
0
 /// <summary>
 /// Gets a list of database data masking rules.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group that contains the resource. You can obtain
 /// this value from the Azure Resource Manager API or the portal.
 /// </param>
 /// <param name='serverName'>
 /// The name of the server.
 /// </param>
 /// <param name='databaseName'>
 /// The name of the database.
 /// </param>
 public static IEnumerable <DataMaskingRule> ListByDatabase(this IDataMaskingRulesOperations operations, string resourceGroupName, string serverName, string databaseName)
 {
     return(operations.ListByDatabaseAsync(resourceGroupName, serverName, databaseName).GetAwaiter().GetResult());
 }