What are the benefits of using an add-on third-party injection container using the built-in i?

I created the IoC container a long time ago, watching this show http://www.dnrtv.com/default.aspx?showNum=126 a few months ago, and made a small sample using it, and worked perfectly.

Now I use unity as a dependency injection container in the project that I am running, and also tried NInject on the previous small MVC website.

But now I ask myself that these containers benefit from what I created from the show, I just see that it is loading from the configuration file that I can do in my own, is there anything else that I am missing? I just want someone to tell me that you should use these containers for 1, 2, 3 reasons that are better than yours.

+3
source share
2 answers

Firstly, these containers are widely used, therefore they are well tested in real situations - I do not know about yours.

They are also well documented and familiar to many developers, so if you work in a team, you do not need to teach others about yourself.

( ), .

, , , ?

+7

IoC:

  • , , .
  • .
  • -
  • , ,
  • (, MVC, WCF ..)
  • .

, , .

-, ( Autofac, Ninject, Unity ..), .

+4

Source: https://habr.com/ru/post/1776066/


All Articles