Inversion of Control Containers Beyond Constructor Injection
summary
Claim: IoC containers do far more than constructor injection and can compose decorators, aliases and contextual bindings so small single‑responsibility classes assemble automatically. Examples use PSR-11, Symfony, Laravel and the League containers and show reflection auto‑resolution, contextual binding for different filesystem configs, sharing/singletons, tagging and container resolving hooks to inject method dependencies or soft resolvers. A worked example composes an FTP storage wrapped by logging and caching decorators and demonstrates resolving circular dependencies by injecting a queue as a soft dependency.
AI-written summary · about
chapters (19)
- 0:00Introduction
- 2:40Design Patterns
- 12:42Implementations
- 14:27Automatic Object Resolution
- 17:12Help the Container
- 19:08Dependencies
- 22:10Contextual Binding
- 25:19Container Events
- 27:02Container Injection
- 28:45Soft Dependencies
- 30:23Config Variables
- 32:18Service Providers
- 33:32When and How
- 35:25Using Arguments
- 36:31Calling Functions
- 38:24Reflection Functions
- 40:10Tagging
- 41:35Circular dependencies
- 43:44Recap
related talks
27mDemystifying Dependency Injection Containers
02h 23mMastering Symfony 4's Dependency Injection
55m.NET Core Dependency Injection – The Booster Jab
48mShoehorning dependency injection into a FP language - What does it take?
01h 02mRefactoring C++ Code for Unit testing with Dependency Injection
02h 37mSymfony 4 best practices (Part 2)
43mDependency Injection Pattern for iOS App
48mPackage Design Principles in Practice
