示例#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;
        }