F
F
floppa3222020-06-01 21:38:33
Software design
floppa322, 2020-06-01 21:38:33

What problems does the DI framework solve?

Hello everybody. Correctly, do I understand that the goal of dependency injection is to centralize the initialization of objects in one place, such as in an xml file with beans, if we consider Spring Core?

That is, when the project has a million packages and, accordingly, a million classes , it is very inconvenient to scour the entire project in order to slip some class other than the current implementation of the class, say, to test something or just change the behavior of the system, it is much better when for it is a special single config file.

Are there any other problems that DI solves?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
M
Maxim, 2020-06-01
@myks92

Description from Yii and Symfony

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question