软件开发原则Software Principles

(1)避免重复原则(DRY - Don't repeat yourself)
http://en.wikipedia.org/wiki/Don%27t_repeat_yourself

(2)简单原则(KISS - Keep it simple, stupid)
http://en.wikipedia.org/wiki/KISS_principle

(3)适可而止原则(YAGNI - You aren't gonna need it)
http://en.wikipedia.org/wiki/You_aren%27t_gonna_need_it

(4)SOLID原则
http://en.wikipedia.org/wiki/SOLID_(object-oriented_design)
S 单一责任原则Single responsibility principle
O 开闭原则Open/closed principle
L 里氏代换原则Liskov substitution principle
I 接口隔离原则Interface segregation principle
D 依赖倒转原则Dependency inversion principle

(5)三次原则(Rule of three)
http://en.wikipedia.org/wiki/Rule_of_three_(computer_programming)

(6)迪米特法则(LoD - Law of Demeter)
又叫作最少知识原则(principle of least knowledge)
http://en.wikipedia.org/wiki/Law_of_Demeter

(7)维尔特法则(Wirth's law)
http://en.wikipedia.org/wiki/Wirth%27s_law

(8)布鲁克斯法则(Brooks's law)
http://en.wikipedia.org/wiki/Brooks%27s_law

(9)康威法则(Conway's law)
http://en.wikipedia.org/wiki/Conway%27s_Law

(10)伯斯塔尔法则(Postel's law)
https://en.wikipedia.org/wiki/Robustness_principle

(11)最小惊讶原则(POLA - Principle of least astonishment)
http://en.wikipedia.org/wiki/Principle_of_least_astonishment

参考:
http://www.artima.com/weblogs/viewpost.jsp?thread=331531
http://code.tutsplus.com/tutorials/3-key-software-principles-you-must-understand--net-25161

猜你喜欢

转载自rensanning.iteye.com/blog/2095194