摘要: //以下代码来源: 设计模式精解-GoF 23种设计模式解析附C++实现源码 //Context.h #pragma once class Context { public: Context(); ~Context(); protected: private: }; //Context.cpp #i 阅读全文
posted @ 2019-12-24 11:36 fourmii 阅读(189) 评论(0) 推荐(0) 编辑
摘要: //以下代码来源: 设计模式精解-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) 编辑