依赖倒置原则-Dependency Inversion Principle (DIP) 里氏替换原则-Liskov Substitution Principle (LSP)
基于8个网页-相关网页
依赖倒置原则声明了我们应该将高层模块和低层模块解偶,在高层类和低层类之间引入一个抽象层。
Dependency Inversion Principle states that we should decouple high level modules from low level modules, introducing an abstraction layer between the high level classes and low level classes.
依赖性倒置原则的基本思想就是对象应该依赖于抽象而不是实现。
The basic idea behind dependency inversion is that objects should be dependent upon abstractions and not upon implementations.
开发人员所赞同的一点是:编写良好的代码易于维护,依赖性倒置原则是进行可维护性设计的可靠方法。
One thing developers have come to agree on is that well-written code is maintainable, and the Dependency Inversion Principle is a sure way to design for maintainability.
应用推荐