摘要: 1.单一职责原则(srp):就是设计一个对象,对象的职责要单一.比如设计用户类,将用户的行为和用户的属性分成两个接口,继承的方式设计类.还有一个srp的解释是:there is no more than one reason for a class to change但srp的原则有可能把握的过细,... 阅读全文
posted @ 2014-06-20 01:33 thinkqin 阅读(277) 评论(0) 推荐(0) 编辑