2017年11月29日
摘要: The KISS principle, or Keep It Simple, Stupid, spans many trades, industries, and professions. The more complex something is, the more ways there are 阅读全文
posted @ 2017-11-29 16:16 鲁传兵 阅读(318) 评论(0) 推荐(0) 编辑
摘要: YAGNI, or “You Ain’t Gonna Need It” (or “You Aren’t Gonna Need It”), emerged as one of the key principles of Extreme Programming. Put another way, the 阅读全文
posted @ 2017-11-29 16:11 鲁传兵 阅读(222) 评论(0) 推荐(0) 编辑
摘要: The Don’t Repeat Yourself (DRY) principle states that duplication in logic should be eliminated via abstraction; duplication in process should be elim 阅读全文
posted @ 2017-11-29 14:37 鲁传兵 阅读(319) 评论(0) 推荐(0) 编辑
摘要: In object-oriented programming, and especially in Domain-Driven Design, objects are said to be anemic if they have state but lack behavior. Some kinds 阅读全文
posted @ 2017-11-29 14:27 鲁传兵 阅读(179) 评论(0) 推荐(0) 编辑
摘要: The Tell, Don’t Ask (TDA) principle suggests that it is better to issue an object a command do perform some operation or logic, rather than to query i 阅读全文
posted @ 2017-11-29 14:07 鲁传兵 阅读(203) 评论(0) 推荐(0) 编辑
摘要: The Flags Over Objects anti-pattern occurs when behavior is written outside of an object by inspecting flags (such as status codes), rather than withi 阅读全文
posted @ 2017-11-29 11:05 鲁传兵 阅读(103) 评论(0) 推荐(0) 编辑