# csharp_design_pattern **Repository Path**: arm123/csharp_design_pattern ## Basic Information - **Project Name**: csharp_design_pattern - **Description**: No description available - **Primary Language**: C# - **License**: GPL-3.0 - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 0 - **Created**: 2021-10-05 - **Last Updated**: 2021-10-29 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # CSharp设计模式 #### 介绍 c#语言的设计模式整理 * 创建型模式 主要介绍如何创建对象,如何将客户程序与创建过程的"变化"有效隔离. * 结构型模式 从静态结构出发,分析导致类型结构相互依赖的原因,通过将静态变化因素抽象封装为独立对象的办法梳理对象关系. * 行为型模式 从动态机制出发,分析导致类型调用过程的依赖关系,通过将调用关系/调用过程抽象封装为独立对象的办法,削弱调用过程中的耦合关系. #### 1.创建型模式 5个 这些设计模式提供了一种在创建对象的同时隐藏创建逻辑的方式,而不是使用 new 运算符直接实例化对象。这使得程序在判断针对某个给定实例需要创建哪些对象时更加灵活。 * 工厂模式(Factory Pattern) //实例化延迟到子类 * 抽象工厂模式(Abstract Factory Pattern) //提供一个创建一系列相关对象的接口 * 单例模式(Singleton Pattern) // * 建造者模式(Builder Pattern) //为product各个部件抽象接口 * 原型模式(Prototype Pattern) //复制静态对象 #### 2.结构型模式 8个 这些设计模式关注类和对象的组合。继承的概念被用来组合接口和定义组合对象获得新功能的方式。 * 适配器模式(Adapter Pattern) * 桥接模式(Bridge Pattern) * 过滤器模式(Filter、Criteria Pattern) * 组合模式(Composite Pattern) * 装饰器模式(Decorator Pattern) * 外观模式(Facade Pattern) * 享元模式(Flyweight Pattern) * 代理模式(Proxy Pattern) #### 3.行为型模式 12个 这些设计模式特别关注对象之间的通信。 * 责任链模式(Chain of Responsibility Pattern) * 命令模式(Command Pattern) * 解释器模式(Interpreter Pattern) * 迭代器模式(Iterator Pattern) * 中介者模式(Mediator Pattern) * 备忘录模式(Memento Pattern) * 观察者模式(Observer Pattern) * 状态模式(State Pattern) * 空对象模式(Null Object Pattern) * 策略模式(Strategy Pattern) * 模板模式(Template Pattern) * 访问者模式(Visitor Pattern) #### 软件架构 软件架构说明 #### 安装教程 1. xxxx 2. xxxx 3. xxxx #### 使用说明 1. xxxx 2. xxxx 3. xxxx #### 参与贡献 1. Fork 本仓库 2. 新建 Feat_xxx 分支 3. 提交代码 4. 新建 Pull Request #### 码云特技 1. 使用 Readme\_XXX.md 来支持不同的语言,例如 Readme\_en.md, Readme\_zh.md 2. 码云官方博客 [blog.gitee.com](https://blog.gitee.com) 3. 你可以 [https://gitee.com/explore](https://gitee.com/explore) 这个地址来了解码云上的优秀开源项目 4. [GVP](https://gitee.com/gvp) 全称是码云最有价值开源项目,是码云综合评定出的优秀开源项目 5. 码云官方提供的使用手册 [https://gitee.com/help](https://gitee.com/help) 6. 码云封面人物是一档用来展示码云会员风采的栏目 [https://gitee.com/gitee-stars/](https://gitee.com/gitee-stars/)