Edmund's zone

导航

公告

随笔分类

随笔档案

最新评论

统计

常用链接

阅读排行榜

评论排行榜

06 2011 档案

策略模式
摘要: 今天研究一下策略模式。示例程序如下:Strategy.csnamespace StrategyPatternExample{ public interface Strategy { int Execute(int a, int b); }}Context.csnamespace StrategyPatternExample{ public class Context { private Strategy strategy; public Context(Strategy strategy) { this.strategy = strategy; } public int ExecuteStra阅读全文

posted @ 2011-06-30 09:31 Edmund Li 阅读(85) | 评论 (0) 编辑