
设计模式
JustEasyCode
只写最简单的代码
展开
专栏收录文章
- 默认排序
- 最新发布
- 最早发布
- 最多阅读
- 最少阅读
-
命令模式
public abstract class Command { public abstract void Execute(); } public class ConcreteCommand1 : Command { string param; public Receiver1 receiver; public ConcreteCommand1(string p,R...原创 2020-01-02 14:08:14 · 128 阅读 · 0 评论 -
组合模式
组合模式实现的是一种树形结构。 using System; using System.Collections.Generic; public abstract class Component { string _Name; public Component(string name) { this._Name = name; } publ...原创 2020-01-01 22:17:41 · 118 阅读 · 0 评论 -
享元模式
using UnityEngine; public class ConcreteFlyWeight : FlyWeight { public ConcreteFlyWeight(string name):base(name) { } public override void Operation() { Debug.Log("执行" + Nam...原创 2020-01-01 16:25:33 · 127 阅读 · 0 评论