設計模式并不是很複雜,但是掌握确實不易,其實自己做的過程中也會有意無意的用到設計模式,或者是programming idioms。其實idioms離patterns的距離很近,或者也可以說很遠,抽象的高度還是不在一個級别上。 嗯~~最近看得感覺也就這些吧,再寫下重要的幾點來提醒自己: 1 favor composition to inheritance 2 encapsulate what varies 3 depend on abstract not implementation 4 keep easy and stupid 5 never use inheritance only in sake of code reuse 6 maintainance resuable is always more important than code 7 one class one goal K, that's it, I'll complete this remainder later when I got more