开发者

Possible to Define Filter in Fluent NHibernate FluentMappings?

开发者 https://www.devze.com 2023-01-20 01:23 出处:网络
When using auto mappings in Fluent NHibernate, you have the ability to do something like: _configuration =

When using auto mappings in Fluent NHibernate, you have the ability to do something like:

                _configuration =
    开发者_运维技巧Fluently.Configure().
        Database(
        MsSqlConfiguration.MsSql2000.ConnectionString(
            @"some connection string")
        )
        .Mappings(
        m => m.AutoMappings.Add(AutoMap.AssemblyOf<GSAContract>().Where(x=>x.Namespace == "SomeNamespace")))
        .BuildConfiguration();

I'm looking to be able to do something similar with FluentMappings, but I can't seem to figure out a similar behavior (filtering on Namespace).


If you won't supply a ClassMap for a class it won't be mapped.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号