예제 #1
0
        /// <summary>
        /// This method obtains the DBConfiguration object throught he ConfigurationFactory
        /// </summary>
        public DBConfiguration getDBConfiguration()
        {
            try
            {
                dbConfig = configFactory.getDBConfiguration();
            }catch(Exception e){

                log.Debug("Error getting DBConfiguration object from ConfigurationFactory: " + e.ToString());

            }
            return dbConfig;
        }
 /// <summary>
 /// This method obtains the DBConfiguration object throught he ConfigurationFactory
 /// </summary>
 public DBConfiguration getDBConfiguration()
 {
     dbConfig = configFactory.DbConfiguration;
         return dbConfig;
 }
예제 #3
0
 /// <summary>
 /// Returns a SQLConnection for Microsoft SQL Server
 /// </summary>
 /// <param name="dbConfig"></param>
 /// <returns></returns>
 private System.Data.SqlClient.SqlConnection getSQLConnection(DBConfiguration dbConfig)
 {
     return new SqlConnection();
 }
예제 #4
0
 /// <summary>
 /// Returns an OracleConnection object
 /// </summary>
 /// <param name="dbConfig"></param>
 /// <returns></returns>
 private OracleConnection getOracleConnection(DBConfiguration dbConfig)
 {
     return new OracleConnection();
 }
예제 #5
0
        internal DBConfiguration getDBConfiguration()
        {
            if (dbConfig == null)
            {

                try
                {

                    // Retrieve DB configuration settings from app.config file
                    dbConfig = System.Configuration.ConfigurationManager.GetSection("MigrationDatabaseSettings") as DBConfiguration;

                }
                catch (Exception e)
                {

                    log.Fatal("Error retrieving MigrationDatabaseSettings: " + e.StackTrace);
                    throw new ApplicationException("ConfigurationFactory::getDBConfiguration - error retrieving DB Configuration settings:" + e.StackTrace);
                }

            }
            return dbConfig;
        }