The purpose of this blog: ① summary of their own learning process, equivalent to study notes ② to share their own experience to everyone, learn from each other, communication, not commercial
content inevitably appear problems, welcome to correct, exchange, discussion, you can leave a message, can also be contacted by the following ways.
I Internet technology enthusiasts, Internet technology enthusiasts
Weibo: Ivan is in 0221
qq:951226918
--------------------------------------------------------------------------------------------------------------- --------------------------------------------------------------------------------------------------------------- -----------------------------
1.IOC and DI
1) IOC (inversion of Control): The idea is to reverse the direction of resource acquisition . The traditional resource lookup method requires that the component initiate a request lookup resource to the container. In response, the container returns resources in a timely manner. When the IOC is applied, it is the container that proactively pushes the resources to the components it manages, and what the component does is to choose an appropriate way to accept resources . This behavior is also known as the passive form of finding
2) Another way to express DI (Dependency injection)-IOC is that the component accepts resource injections from such containers in a pre-defined way (for example, setter methods) . In contrast to the IOC, this statement is more straightforward
2. Comparison between traditional and IOC methods
Evolution of the 3.IOC
3---
[Original]java Web learning Note 97:spring Learn---Bean configuration in Spring: IOC and DI