Injection injection: should we all know this?

One of my friends (he, like me, a .NET / C ++ developer) asked me:

Enabling addiction: should we all know this? Why?

Could you tell:

  • Your opinion: do we really need to know this template and how to implement it?
  • Good link (link) that could explain why?

Thank you very much.

PS I understand that I ask a lot ... but I can not find a good link myself ...

+3
source share
4 answers

Good comments are posted here, but there is no clear answer to the question "Your opinion: do we really need to know this template and how to implement it?"

, "", :

  • () ;
  • ;
  • .

"?" .

.

+1

- . , , . DI , Injection Dependency .NET. , . - #, .

+4

Dependency Injection - , , , . , , , , , . , unit test .

IoC ( ) , SO. , Injection Dependency, IoC DI.

- , IOC?

Also, here are some good links explaining DI in more detail:

+3
source

Here is a really good reference, why dependency injection is crucial for writing (a unit) of test code:

http://www.youtube.com/watch#!v=wEhu57pih5w&feature=related

("Clean Codes" - "Testing Modules")

+2
source

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


All Articles