策略模式 定义: Identify the aspects of your application that vary and separate them from what stays the same.(找到系统中变化的部分,将变化的部分同其它稳定的部分隔开。) 针对问题:同一个父类的子类之间有着不同的行为,一般的方式我们会在父类中定义抽象方法,在子类中重写该方法。然而在具体的应用中,可能有些... Read More
posted @ 2010-06-22 16:45 gistone Views(286) Comments(0) Diggs(0)