/// <summary>
 /// Initializes a new instance of the SqlManagementClient class.
 /// </summary>
 /// <param name='httpClient'>
 /// The Http client
 /// </param>
 public SqlManagementClient(HttpClient httpClient)
     : base(httpClient)
 {
     this._auditingPolicy           = new AuditingPolicyOperations(this);
     this._databaseActivation       = new DatabaseActivationOperations(this);
     this._databaseBackup           = new DatabaseBackupOperations(this);
     this._databases                = new DatabaseOperations(this);
     this._dataMasking              = new DataMaskingOperations(this);
     this._elasticPools             = new ElasticPoolOperations(this);
     this._firewallRules            = new FirewallRuleOperations(this);
     this._capabilities             = new LocationCapabilitiesOperations(this);
     this._recommendedElasticPools  = new RecommendedElasticPoolOperations(this);
     this._recommendedIndexes       = new RecommendedIndexOperations(this);
     this._databaseReplicationLinks = new ReplicationLinkOperations(this);
     this._secureConnection         = new SecureConnectionPolicyOperations(this);
     this._serverAdministrators     = new ServerAdministratorOperations(this);
     this._servers                            = new ServerOperations(this);
     this._serverUpgrades                     = new ServerUpgradeOperations(this);
     this._serviceObjectives                  = new ServiceObjectiveOperations(this);
     this._serviceTierAdvisors                = new ServiceTierAdvisorOperations(this);
     this._transparentDataEncryption          = new TransparentDataEncryptionOperations(this);
     this._apiVersion                         = "2014-04-01";
     this._longRunningOperationInitialTimeout = -1;
     this._longRunningOperationRetryTimeout   = -1;
     this.HttpClient.Timeout                  = TimeSpan.FromSeconds(300);
 }
Esempio n. 2
0
 /// <summary>
 /// Returns information about the Azure SQL capabilities available for
 /// the specified region.
 /// </summary>
 /// <param name='operations'>
 /// Reference to the
 /// Microsoft.Azure.Management.Sql.ILocationCapabilitiesOperations.
 /// </param>
 /// <param name='locationName'>
 /// Required. The name of the region for which the Azure SQL
 /// capabilities are retrieved.
 /// </param>
 /// <returns>
 /// Represents the response to a Get Azure Sql capabilities request
 /// </returns>
 public static LocationCapabilitiesGetResponse Get(this ILocationCapabilitiesOperations operations, string locationName)
 {
     return(Task.Factory.StartNew((object s) =>
     {
         return ((ILocationCapabilitiesOperations)s).GetAsync(locationName);
     }
                                  , operations, CancellationToken.None, TaskCreationOptions.None, TaskScheduler.Default).Unwrap().GetAwaiter().GetResult());
 }
Esempio n. 3
0
 /// <summary>
 /// Returns information about the Azure SQL capabilities available for
 /// the specified region.
 /// </summary>
 /// <param name='operations'>
 /// Reference to the
 /// Microsoft.Azure.Management.Sql.ILocationCapabilitiesOperations.
 /// </param>
 /// <param name='locationName'>
 /// Required. The name of the region for which the Azure SQL
 /// capabilities are retrieved.
 /// </param>
 /// <returns>
 /// Represents the response to a Get Azure Sql capabilities request
 /// </returns>
 public static Task <LocationCapabilitiesGetResponse> GetAsync(this ILocationCapabilitiesOperations operations, string locationName)
 {
     return(operations.GetAsync(locationName, CancellationToken.None));
 }