上一页 1 ··· 3 4 5 6 7 8 9 10 11 ··· 20 下一页
摘要: //以下代码来源: 设计模式精解-GoF 23种设计模式解析附C++实现源码 //Aggregate.h #pragma once class Iterator; typedef int Object; class Interator; class Aggregate { public: virtu 阅读全文
posted @ 2019-12-24 11:16 fourmii 阅读(231) 评论(0) 推荐(0) 编辑
摘要: //以下代码来源: 设计模式精解-GoF 23种设计模式解析附C++实现源码 //Handle.h #pragma once class Handle { public: virtual ~Handle(); virtual void HandleRequest() = 0; void SetSuc 阅读全文
posted @ 2019-12-24 10:05 fourmii 阅读(334) 评论(0) 推荐(0) 编辑
摘要: //以下代码来源: 设计模式精解-GoF 23种设计模式解析附C++实现源码 //Visitor.h #pragma once class ConcreateElementA; class ConcreateElementB; class Element; class Visitor { publi 阅读全文
posted @ 2019-12-24 09:35 fourmii 阅读(252) 评论(0) 推荐(0) 编辑
摘要: //方式一 //Reciever.h #pragma once class Reciever{ public: Reciever(); ~Reciever(); void Action(); protected: private: }; //Reciever.cpp #include"Recieve 阅读全文
posted @ 2019-12-23 17:49 fourmii 阅读(203) 评论(0) 推荐(0) 编辑
摘要: 以下代码来源: 设计模式精解-GoF 23种设计模式解析附C++实现源码 //Mediator.h #pragma once class Colleage; class Mediator { public: virtual ~Mediator(); virtual void DoActionFrom 阅读全文
posted @ 2019-12-23 16:52 fourmii 阅读(248) 评论(0) 推荐(0) 编辑
摘要: 以下代码来源: 设计模式精解-GoF 23种设计模式解析附C++实现源码 //Memento.h #pragma once #include<string> class Memento; class Originator{ public: typedef std::string State; Ori 阅读全文
posted @ 2019-12-23 14:42 fourmii 阅读(233) 评论(0) 推荐(0) 编辑
摘要: 以下代码来源: 设计模式精解-GoF 23种设计模式解析附C++实现源码 //Subject.h #pragma once #include<list> #include<string> typedef std::string State; class Observer; class Subject 阅读全文
posted @ 2019-12-23 10:50 fourmii 阅读(395) 评论(0) 推荐(0) 编辑
摘要: 以下代码来源: 设计模式精解-GoF 23种设计模式解析附C++实现源码 //Context.h #pragma once class State; class Context { public: Context(); Context(State* st); virtual ~Context(); 阅读全文
posted @ 2019-12-22 16:17 fourmii 阅读(232) 评论(0) 推荐(0) 编辑
摘要: 以下代码来源: 设计模式精解-GoF 23种设计模式解析附C++实现源码 //strategy.h #pragma once class Strategy { public: Strategy(); virtual ~Strategy(); virtual void AlgrithmInferenc 阅读全文
posted @ 2019-12-22 14:22 fourmii 阅读(272) 评论(0) 推荐(0) 编辑
摘要: 以下代码来源: 设计模式精解-GoF 23种设计模式解析附C++实现源码 //Template.h class AbstractClass { public: virtual ~AbstractClass(); void TemplateMethod(); protected: virtual vo 阅读全文
posted @ 2019-12-22 10:41 fourmii 阅读(206) 评论(0) 推荐(0) 编辑
上一页 1 ··· 3 4 5 6 7 8 9 10 11 ··· 20 下一页