Design Patterns - Inversion of Control / Dependency Injection

design-patterns

https://www.youtube.com/watch?v=DcNtg4_i-2w
https://www.youtube.com/watch?v=I6-QI1qN4pU - Deep Dive into Dependency Injection and Writing
https://www.youtube.com/watch?v=IKD2-MAkXyQ
https://www.youtube.com/watch?v=wXPZl3uS888
https://www.youtube.com/watch?v=CrFfmG40p1Q

https://www.tutorialspoint.com/spring/spring_dependency_injection.htm
http://www.javacreed.com/why-should-we-use-dependency-injection/

What is dependency injection?

If you class instantiate an object, we says that our class depends on that object. Instead of instantiating that object inside our class, we should move the code that instantiate the object outside our class. The code that use our class is responsible for creating the object that we need and provide it to us either by passing it to our constructor, or provide it to our class by invoking one of our setter method.

Unless otherwise stated, the content of this page is licensed under Creative Commons Attribution-ShareAlike 3.0 License