摘要: DIP 依赖反转原则 Dependency Inversion Principle 的定义如下: 高级别的模块不应该依赖于低级别的模块, 他们都应该依赖于抽象. 假设Controller依赖于Repository的实例/实现, 而不是interface: 这个例子里面Controller是高级别模块 阅读全文
posted @ 2018-03-16 14:45 yangxu-pro 阅读(1624) 评论(3) 推荐(11) 编辑