项目
在 GitHub 查看
wataridori/solid-php-example
关于
PHP 中 SOLID 设计原则的示例
学习与教育实测星标增长
- 24小时
- 0
- 7天
- 0
- 15天
- -1
- 1个月
- 正在收集历史
各周期内的星标净变化,周期相互重叠,并非每日新增。缺失的测量保持空白。星标代表关注度,不代表软件质量。
README.md
原文SOLID Principles Examples in PHP
Single Responsibility Principle (Example)
This principle is about actors and high level architecture.
A class should have one, and only one, reason to change.
Open Closed Principle (Example)
This principle is about class design and feature extensions.
A class should be open for extension, but closed for modification.
Liskov Substitution Principle (Example)
This principle is about subtyping and inheritance
Derived classes must be substitutable for their base classes.
Interface Segregation Principle (Example)
This principle is about business logic to clients communication.
Many client-specific interfaces are better than one general-purpose interface.
Dependency Inversion Principle (Example)
This principle wires up all other four principles in a single circle.
Depend upon abstractions. Do not depend upon concretions.
For more information about Object Oriented Design Principles, you can refer this slide
探索相关项目
加载中…