哪个版本的流利nhibernate是兼容nhibernate 3.2 [英] which version of fluent nhibernate is compatible with nhibernate 3.2

查看:133
本文介绍了哪个版本的流利nhibernate是兼容nhibernate 3.2的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我看到当我从Nuget安装流利的nhibernate 1.2时,它下载了nhibernate 3.1。如果我想使用nhibernate 3.2,我将如何通过nuget做到这一点,并与流利的nhibernate 1.2兼容?

现在 ,来自官方NuGet包源代码的FluentNHibernate包依赖于NHibernate.Castle 3.1(目前还没有更新的版本),而NHibernate 3.1依赖于NHibernate 3.1(准确版本,不是3.1或更高版本)。因此,当安装FluentNHibernate时,NuGet推断对NHibernate 3.1的依赖。因此,底线是:你不能,直到FluentNHibernate包被更新为止。



最实用的方法是获取最新的FluentNHibernate源代码,并将其与NHibernate 3.2构建。我已经测试过,它似乎工作得很好。你甚至可以使用程序集绑定重定向,但我还没有测试。



另外,你可以等待NHibernate 3.2到达GA(final)和FluentNHibernate赶上,但当然这不是一个非常令人满意的答案。


i see when i install fluent nhibernate 1.2 from Nuget, it downloads nhibernate 3.1. If i want to use nhibernate 3.2, how would i do that through nuget and it is compatible with fluent nhibernate 1.2 ?

解决方案

Currently, the FluentNHibernate package from the offical NuGet package source, depends on NHibernate.Castle 3.1 (currently, there is no newer version yet), which in turn depends on NHibernate 3.1 (the exact version, not 3.1 or higher). Therefore, NuGet infers a dependency on NHibernate 3.1 when installing FluentNHibernate.

So the bottom line is: you can't, until the FluentNHibernate package is updated.

The most practical way around is getting the latest FluentNHibernate source code and building it against NHibernate 3.2. I've tested that and it seems to work just fine. You might even be fine using assembly binding redirects, but I haven't tested that.

Alternatively, you can wait for NHibernate 3.2 to reach GA (final) and FluentNHibernate to catch up, but of course that's not a very satisfying answer.

这篇关于哪个版本的流利nhibernate是兼容nhibernate 3.2的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆