Castle Windsor: Register components across multiple projects in solution

后端 未结 4 1935
自闭症患者
自闭症患者 2021-01-13 15:48

I would like to use Castle Windsor for dependency injection for my solution consisting of the following projects:

  1. Mvc [ASP.NET MVC 3 Web Appli
4条回答
  •  一整个雨季
    2021-01-13 16:16

    You have to ask yourself one thing: "do I really need 4 different assemblies for my MVC project?" You should break the code into assemblies according to deployment boundaries, not just based on some vague notion that Model code should be physically separate from Business code & similar. You should use namespaces for such things instead of separate projects.

    Here's a good article on this issue: Advices on partitioning code through .NET assemblies by Patrick Smacchia.

提交回复
热议问题