Skip to content

Instantly share code, notes, and snippets.

@subdigital
Created December 23, 2009 16:27
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save subdigital/262617 to your computer and use it in GitHub Desktop.
Save subdigital/262617 to your computer and use it in GitHub Desktop.
These are just so I can refer to them later.
<?xml version="1.0" encoding="utf-8" ?>
<hibernate-mapping xmlns="urn:nhibernate-mapping-2.2"
assembly="YOUR_ASSEMBLY"
namespace="YOUR_NAMESPACE">
<class name="Foo" table="foos">
<id name="id">
<generator class="identity"/>
</id>
<property name="Bar" not-null="true"/>
</class>
</hibernate-mapping>
<?xml version="1.0" encoding="utf-8" ?>
<hibernate-configuration xmlns="urn:nhibernate-configuration-2.2">
<session-factory name="MySessionFactory">
<property name="dialect">NHibernate.Dialect.MsSql2005Dialect</property>
<property name="connection.provider">NHibernate.Connection.DriverConnectionProvider</property>
<property name="connection.driver_class">NHibernate.Driver.SqlClientDriver</property>
<property name="adonet.batch_size">16</property>
<property name="current_session_context_class">web</property>
<property name="proxyfactory.factory_class">NHibernate.ByteCode.LinFu.ProxyFactoryFactory, NHibernate.ByteCode.LinFu</property>
<mapping assembly="YOUR_MAPPING_ASSEMBLY"/>
</session-factory>
</hibernate-configuration>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment