2013年7月23日

面试总结之 oop desing 之 The Strategy Pattern

摘要: The Strategy Pattern defines a family of algorithms,encapsulates each one, and makes them interchangeable.Strategy lets the algorithm vary independently fromclients that use it.1.Duck 问题(head frist oop)有的能飞,有的能叫,经典问题.//Duck.javapublic abstract class Duck {FlyBehavior flyBehavior;QuackBehavior quackB 阅读全文

posted @ 2013-07-23 13:18 brave_bo 阅读(196) 评论(0) 推荐(0)

导航