public Configuration GetConfiguration(IConfiguration facilityConfiguration) { var defaultConfigurationBuilder = new DefaultConfigurationBuilder(); var configuration = defaultConfigurationBuilder.GetConfiguration(facilityConfiguration); configuration.AddAutoMappings(CreateAutomappings()); return configuration; }
public Configuration GetConfiguration(IConfiguration facilityConfiguration) { var defaultConfigurationBuilder = new DefaultConfigurationBuilder(); var configuration = defaultConfigurationBuilder.GetConfiguration(facilityConfiguration); configuration.AddMappingsFromAssembly(typeof(Usuario).Assembly); return configuration; }
public Configuration GetConfiguration(IConfiguration config) { _configurationsCreated++; Configuration nhConfig = new DefaultConfigurationBuilder().GetConfiguration(config); nhConfig.Properties["dialect"] = ConfigurationManager.AppSettings["nhf.dialect"]; nhConfig.Properties["connection.driver_class"] = ConfigurationManager.AppSettings["nhf.connection.driver_class"]; nhConfig.Properties["connection.provider"] = ConfigurationManager.AppSettings["nhf.connection.provider"]; nhConfig.Properties["connection.connection_string"] = ConfigurationManager.AppSettings["nhf.connection.connection_string.1"]; if (config.Attributes["id"] != "sessionFactory1") { nhConfig.Properties["connection.connection_string"] = ConfigurationManager.AppSettings["nhf.connection.connection_string.2"]; } nhConfig.Properties["proxyfactory.factory_class"] = ConfigurationManager.AppSettings["nhf.proxyfactory.factory_class"]; return nhConfig; }