码迷,mamicode.com
首页 >  
搜索关键字:a stone removing gam    ( 709个结果
Java 实现解释器(Interpreter)模式
/** * 声明一个抽象的解释操作 * @author stone * */ public interface Interpreter { public void interpret(Context context); //实际中,可以有个返回的类型,定义解释出的数据对象 } public class XmlSaxInterpreter implements Interpreter...
分类:编程语言   时间:2014-10-14 19:23:49    阅读次数:167
Java 实现中介者(Mediator)模式
类图 public interface IMediator { public void createMediator(); public void work(); } /** * 中介、调节实际上需要交互的两个元素,让其松耦合 * @author stone * */ public class Mediator implements IMediator { pr...
分类:编程语言   时间:2014-10-14 18:44:59    阅读次数:192
removing vmware debugger from visual studio
removing vmware debugger from visual studiobyRosson 十月 14, 2010 at 5:30 下午 underVisual Studio|VMWareA quick tip to anyone who's having trouble with re...
分类:系统相关   时间:2014-10-14 17:26:49    阅读次数:211
Java 实现状态(State)模式
/** * @author stone */ public class WindowState { private String stateValue; public WindowState(String stateValue) { this.stateValue = stateValue; } public String getStateValue() { retur...
分类:编程语言   时间:2014-10-14 00:46:17    阅读次数:217
Java 实现备忘录(Memento)模式
/** * 数据对象 * @author stone * */ public class DataState { private String action; public void setAction(String action) { this.action = action; } public String getAction() { return action;...
分类:编程语言   时间:2014-10-13 23:20:27    阅读次数:250
Java 实现责任链(Chain of Responsibility)模式
类图 /** * 抽象责任 * @author stone * */ public abstract class IFilter { private IFilter successor; public IFilter getSuccessor() { return successor; } public void setSuccessor(IFilter succ...
分类:编程语言   时间:2014-10-11 22:06:46    阅读次数:248
Java 实现迭代器(Iterator)模式
类图 /** * 自定义集合接口, 类似java.util.Collection * 用于数据存储 * @author stone * */ public interface ICollection { IIterator iterator(); //返回迭代器 void add(T t); T get(int index); } /** * 自定义迭代器接口 类...
分类:编程语言   时间:2014-10-11 15:17:15    阅读次数:172
Java 实现观察者(Observer)模式
1. Java自带的实现 类图 /** * 观察目标 继承自 java.util.Observable * @author stone * */ public class UpdateObservable extends Observable { private int data; public UpdateObservable(Observer observer)...
分类:编程语言   时间:2014-10-10 21:37:14    阅读次数:285
Java 实现策略(Strategy)模式
/** * 策略模式:针对同一命令(或行为),不同的策略做不同的动作 * 商品促销 * 本类为:收取现金的类 * * @author stone */ public interface ICashSuper { double acceptCash(double money); } /** * 正常收取现金 * @author stone * */ public ...
分类:编程语言   时间:2014-10-10 19:17:14    阅读次数:148
Java 实现模板方法(TemplateMethod)模式
类图 /** * 业务流程模板,提供基本框架 * @author stone * */ public abstract class BaseTemplate { public abstract void part1(); public abstract void part2(); public abstract void part3(); //这里为了严格实验结...
分类:编程语言   时间:2014-10-10 18:58:14    阅读次数:222
709条   上一页 1 ... 60 61 62 63 64 ... 71 下一页
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!