IoC容器和Dependency Injection模式

依赖注入的形式主要有三种,我分别将它们叫做

(1)构造函数注入(ConstructorInjection);

(2)设值方法注入(SetterInjection);

(3)接口注入(Interface Injection)。

你可能感兴趣的:(IoC容器和Dependency Injection模式)