Ok I can do it like this
Configuration cfg = LoadDefaultConfiguration();
_sessionFactory = Fluently.Configure
(cfg).BuildSessionFactory();
but how do I add mapping assembly. Any ideas? nhibernate.config has
mapping tag but is does not seem to work.
On Mar 1, 8:38 am, epitka <[email protected]> wrote:
> hi,
> Is there a way to load nhibernate.config directly through fluent? I
> have a common assembly that I use for all NH project that deals with
> sessions, config etc. Now I would like to be able to map entities
> using Fluent but configure using normal nhibernate.config. Why? Well
> for one in this line for example I don't know the assembly name, it is
> specified in nhibernate.config.
> .Mappings(m =>
> m.FluentMappings.AddFromAssemblyOf<Program>())
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Fluent NHibernate" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/fluent-nhibernate?hl=en
-~----------~----~----~----~------~----~------~--~---