- Mastering Spring 5.0
- Ranga Rao Karanam
- 34字
- 2021-07-02 22:12:05
Dependency injection types
In the previous example, we used a setter method to wire in the dependency. There are two types of dependency injections that are used frequently:
- The setter injection
- The constructor injection