Beispiel #1
0
        public static IHotelTravelServiceProvider GetHotelTravelServiceProvider(ProviderTypes provider)
        {
            //if (provider == ProviderTypes.Tourico)
            //{
            //    return new TouricoHotelTravelServiceProvider();
            //}

            throw new NotImplementedException(provider.ToString());
        }
        public static IHotelTravelServiceProvider GetHotelTravelServiceProvider(ProviderTypes provider)
        {
            //if (provider == ProviderTypes.Tourico)
            //{
            //    return new TouricoHotelTravelServiceProvider();
            //}

            throw new NotImplementedException(provider.ToString());
        }
Beispiel #3
0
 public DataSource(ProviderTypes providerType, string connectionString)
 {
     ProviderType       = providerType;
     ProviderTypeString = providerType.ToString();
     ConnectionString   = connectionString;
     if (ProviderType == ProviderTypes.SqlServer)
     {
         DbConnectionType = typeof(SqlConnection);
     }
 }
Beispiel #4
0
 public DataSource(string key, ProviderTypes providerType, string connectionString, int version = 0)
 {
     Key                = key;
     ProviderType       = providerType;
     ProviderTypeString = providerType.ToString();
     ConnectionString   = connectionString;
     if (ProviderType == ProviderTypes.SqlServer)
     {
         DbConnectionType = typeof(SqlConnection);
     }
     else if (ProviderType == ProviderTypes.DB2iSeries)
     {
         DbConnectionType = AppDomain.CurrentDomain.GetAssemblies()
                            .Where(x => x.GetName().Name == "IBM.Data.DB2.iSeries")
                            .SelectMany(x => x.GetTypes().Where(t => t.Name == "iDB2Connection"))
                            .FirstOrDefault();
     }
     Version = version;
 }