This class is responsible for all the REST communication with the audit REST endpoints
 /// <summary>
 /// Constructs a database adapter
 /// </summary>
 /// <param name="profile">The current azure profile</param>
 /// <param name="subscription">The current azure subscription</param>
 public AzureSqlDatabaseReplicationAdapter(AzureContext context)
 {
     Context = context;
     _subscription = context.Subscription;
     ReplicationCommunicator = new AzureSqlDatabaseReplicationCommunicator(Context);
     DatabaseCommunicator = new AzureSqlDatabaseCommunicator(Context);
     ServerCommunicator = new AzureSqlServerCommunicator(Context);
 }
 /// <summary>
 /// Constructs a database adapter
 /// </summary>
 /// <param name="profile">The current azure profile</param>
 /// <param name="subscription">The current azure subscription</param>
 public AzureSqlDatabaseReplicationAdapter(AzureProfile Profile, AzureSubscription subscription)
 {
     this.Profile = Profile;
     this._subscription = subscription;
     ReplicationCommunicator = new AzureSqlDatabaseReplicationCommunicator(Profile, subscription);
     DatabaseCommunicator = new AzureSqlDatabaseCommunicator(Profile, subscription);
     ServerCommunicator = new AzureSqlServerCommunicator(Profile, subscription);
 }
 /// <summary>
 ///  Checks whether the server is applicable for threat detection
 /// </summary>
 private bool IsRightServerVersionForThreatDetection(string resourceGroupName, string serverName, string clientId)
 {
     AzureSqlServerCommunicator dbCommunicator = new AzureSqlServerCommunicator(Context);
     Management.Sql.Models.Server server = dbCommunicator.Get(resourceGroupName, serverName, clientId);
     return server.Properties.Version == "12.0";
 }
 /// <summary>
 /// Constructs a server adapter
 /// </summary>
 /// <param name="context">The current azure profile</param>
 public AzureSqlServerAdapter(AzureContext context)
 {
     Context = context;
     Communicator = new AzureSqlServerCommunicator(Context);
 }
 /// <summary>
 /// Constructs a server adapter
 /// </summary>
 /// <param name="profile">The current azure profile</param>
 /// <param name="subscription">The current azure subscription</param>
 public AzureSqlServerAdapter(AzureProfile profile, AzureSubscription subscription)
 {
     Profile = profile;
     Communicator = new AzureSqlServerCommunicator(Profile, subscription);
 }