无法解析Castle.TypedFactory.DefaultInterfaceFactoryComponentSelector

Sha*_*lez 11 castle-windsor

我跟随JoséF.Romaniello关于NHibernate会话管理的例子.这是一篇非常好的文章,但是我很难与NHibernate,Windsor和MVC相处很少.

我试图重新创建NHibernateInstaller,但遇到以下错误: Component Castle.TypedFactory.DefaultInterfaceFactoryComponentSelector could not be resolved. Make sure you didn't misspell the name, and that component is registered.

在提供的示例项目中,即使安装程序完全相同且Google未提供任何结果(这是非常不寻常的),也不会出现此错误.是什么导致这种情况以及如何避免?

Jos*_*llo 29

这似乎是TypedFactoryFacility的问题......你这样做吗?

kernel.AddFacility<TypedFactoryFacility>();
Run Code Online (Sandbox Code Playgroud)

在运行所有安装程序之前?