Esempio n. 1
0
 public void Open()
 {
     SqlConnectionManager = new SqlConnectionManager((ConnectionString)ConnectionString);
     SqlConnectionManager.Open();
     Server = new Server(new ServerConnection(SqlConnectionManager.DbConnection));
     Context.StatementTimeout = 0;
 }
Esempio n. 2
0
        public override IDbConnectionManager Clone()
        {
            SqlConnectionManager clone = new SqlConnectionManager((ConnectionString)ConnectionString)
            {
                MaxLoginAttempts = this.MaxLoginAttempts
            };

            return(clone);
        }
Esempio n. 3
0
        public override object Clone()
        {
            SqlConnectionManager clone = new SqlConnectionManager((SqlConnectionString)ConnectionString)
            {
                MaxLoginAttempts = this.MaxLoginAttempts,
                ModifyDBSettings = this.ModifyDBSettings
            };

            return(clone);
        }
Esempio n. 4
0
        public override IConnectionManager Clone()
        {
            if (LeaveOpen)
            {
                return(this);
            }
            SqlConnectionManager clone = new SqlConnectionManager((ConnectionString)ConnectionString)
            {
                MaxLoginAttempts = this.MaxLoginAttempts
            };

            return(clone);
        }
Esempio n. 5
0
 private bool disposedValue = false; // To detect redundant calls
 protected void Dispose(bool disposing)
 {
     if (!disposedValue)
     {
         if (disposing)
         {
             Server?.ConnectionContext?.Disconnect();
             if (SqlConnectionManager != null)
             {
                 SqlConnectionManager.Close();
             }
             SqlConnectionManager = null;
             Server = null;
         }
         disposedValue = true;
     }
 }
Esempio n. 6
0
 public void AfterBulkInsert() => SqlConnectionManager.AfterBulkInsert();
Esempio n. 7
0
 public void BeforeBulkInsert() => SqlConnectionManager.BeforeBulkInsert();
Esempio n. 8
0
 public void BulkInsert(ITableData data, string tableName)
 => SqlConnectionManager.BulkInsert(data, tableName);
Esempio n. 9
0
 public SMOConnectionManager(ConnectionString connectionString)
 {
     //RuntimePolicyHelper.SetNET20Compatibilty();
     ConnectionString     = connectionString;
     SqlConnectionManager = new SqlConnectionManager(connectionString);
 }
Esempio n. 10
0
 public IDbCommand CreateCommand(string commandText, IEnumerable <QueryParameter> parameterList = null)
 => SqlConnectionManager.CreateCommand(commandText, parameterList);
Esempio n. 11
0
 public SMOConnectionManager(ConnectionString connectionString)
 {
     ConnectionString     = connectionString;
     SqlConnectionManager = new SqlConnectionManager(connectionString);
 }
Esempio n. 12
0
 public void AfterBulkInsert(string tableName) => SqlConnectionManager.AfterBulkInsert(tableName);
Esempio n. 13
0
 public void BeforeBulkInsert(string tableName) => SqlConnectionManager.BeforeBulkInsert(tableName);
Esempio n. 14
0
 public void BulkInsert(IDataReader data, IColumnMappingCollection columnMapping, string tableName)
 => SqlConnectionManager.BulkInsert(data, columnMapping, tableName);