In the previous chapter, you saw how DI works and how to use the constructor injection method. However, if you need to inject many instances during runtime, this method can be quite cumbersome and can make it complicated to understand and maintain your code.
Therefore, you can use a more advanced technique of DI called method injection. This allows you to access instances directly from within your code.