CfgSessionFactory INHPersistenceProviderConfigurator.CreateSessionFactory(string connectionString) { return(NHConfigurator.CreateSessionFactory(GetProviderConfigurer(connectionString), MappingsAssembly, cfg => { cfg.SetProperty(global::NHibernate.Cfg.Environment.CurrentSessionContextClass, "thread_static"); // TODO: read from config cfg.SetProperty(global::NHibernate.Cfg.Environment.ReleaseConnections, "on_close"); // TODO: read from config })); }
public void ExportSchemaScript(string connectionString, string filePath) { NHConfigurator.SchemaScriptExport(GetProviderConfigurer(connectionString), MappingsAssembly, filePath, false); }
public void UpdateSchema(string connectionString) { NHConfigurator.SchemaUpdate(GetProviderConfigurer(connectionString), MappingsAssembly); }