From 9b04af4b6a228cf41e6591ad9970c6ce9a59c885 Mon Sep 17 00:00:00 2001 From: Edward Date: Sat, 2 May 2020 17:40:51 +0800 Subject: [PATCH] order sturcture patterns --- README.md | 10 +++++----- structure/{22_bridge => 03_bridge}/README.md | 0 structure/{22_bridge => 03_bridge}/bridge.go | 0 structure/{22_bridge => 03_bridge}/bridge_test.go | 0 structure/{18_flyweight => 04_flyweight}/README.md | 0 structure/{18_flyweight => 04_flyweight}/flyweight.go | 0 .../{18_flyweight => 04_flyweight}/flyweight_test.go | 0 structure/{13_composite => 05_composite}/README.md | 0 structure/{13_composite => 05_composite}/composite.go | 0 .../{13_composite => 05_composite}/composite_test.go | 0 structure/{20_decorator => 06_decorator}/README.md | 0 structure/{20_decorator => 06_decorator}/decorator.go | 0 .../{20_decorator => 06_decorator}/decorator_test.go | 0 structure/{09_proxy => 07_proxy}/README.md | 0 structure/{09_proxy => 07_proxy}/proxy.go | 0 structure/{09_proxy => 07_proxy}/proxy_test.go | 0 16 files changed, 5 insertions(+), 5 deletions(-) rename structure/{22_bridge => 03_bridge}/README.md (100%) rename structure/{22_bridge => 03_bridge}/bridge.go (100%) rename structure/{22_bridge => 03_bridge}/bridge_test.go (100%) rename structure/{18_flyweight => 04_flyweight}/README.md (100%) rename structure/{18_flyweight => 04_flyweight}/flyweight.go (100%) rename structure/{18_flyweight => 04_flyweight}/flyweight_test.go (100%) rename structure/{13_composite => 05_composite}/README.md (100%) rename structure/{13_composite => 05_composite}/composite.go (100%) rename structure/{13_composite => 05_composite}/composite_test.go (100%) rename structure/{20_decorator => 06_decorator}/README.md (100%) rename structure/{20_decorator => 06_decorator}/decorator.go (100%) rename structure/{20_decorator => 06_decorator}/decorator_test.go (100%) rename structure/{09_proxy => 07_proxy}/README.md (100%) rename structure/{09_proxy => 07_proxy}/proxy.go (100%) rename structure/{09_proxy => 07_proxy}/proxy_test.go (100%) diff --git a/README.md b/README.md index c4d0897..d1d2909 100644 --- a/README.md +++ b/README.md @@ -29,11 +29,11 @@ Go常用的、面向工程化和最佳实践的模式套路,包含常见的23 + [x] [外观模式(Facade)](./structure/01_facade) + [x] [适配器模式(Adapter)](./structure/02_adapter) -+ [x] [代理模式(Proxy)](./structure/09_proxy) -+ [ ] [复合模式(Composite)](./structure/13_composite) -+ [x] [享元模式(Flyweight)](./structure/18_flyweight) -+ [ ] [装饰模式(Decorator)](./structure/20_decorator) -+ [x] [桥模式(Bridge)](./structure/22_bridge) ++ [x] [桥模式(Bridge)](./structure/03_bridge) ++ [x] [复合模式(Composite)](./structure/05_composite) ++ [x] [享元模式(Flyweight)](./structure/04_flyweight) ++ [ ] [装饰模式(Decorator)](./structure/06_decorator) ++ [x] [代理模式(Proxy)](./structure/07_proxy) ## 行为型模式 diff --git a/structure/22_bridge/README.md b/structure/03_bridge/README.md similarity index 100% rename from structure/22_bridge/README.md rename to structure/03_bridge/README.md diff --git a/structure/22_bridge/bridge.go b/structure/03_bridge/bridge.go similarity index 100% rename from structure/22_bridge/bridge.go rename to structure/03_bridge/bridge.go diff --git a/structure/22_bridge/bridge_test.go b/structure/03_bridge/bridge_test.go similarity index 100% rename from structure/22_bridge/bridge_test.go rename to structure/03_bridge/bridge_test.go diff --git a/structure/18_flyweight/README.md b/structure/04_flyweight/README.md similarity index 100% rename from structure/18_flyweight/README.md rename to structure/04_flyweight/README.md diff --git a/structure/18_flyweight/flyweight.go b/structure/04_flyweight/flyweight.go similarity index 100% rename from structure/18_flyweight/flyweight.go rename to structure/04_flyweight/flyweight.go diff --git a/structure/18_flyweight/flyweight_test.go b/structure/04_flyweight/flyweight_test.go similarity index 100% rename from structure/18_flyweight/flyweight_test.go rename to structure/04_flyweight/flyweight_test.go diff --git a/structure/13_composite/README.md b/structure/05_composite/README.md similarity index 100% rename from structure/13_composite/README.md rename to structure/05_composite/README.md diff --git a/structure/13_composite/composite.go b/structure/05_composite/composite.go similarity index 100% rename from structure/13_composite/composite.go rename to structure/05_composite/composite.go diff --git a/structure/13_composite/composite_test.go b/structure/05_composite/composite_test.go similarity index 100% rename from structure/13_composite/composite_test.go rename to structure/05_composite/composite_test.go diff --git a/structure/20_decorator/README.md b/structure/06_decorator/README.md similarity index 100% rename from structure/20_decorator/README.md rename to structure/06_decorator/README.md diff --git a/structure/20_decorator/decorator.go b/structure/06_decorator/decorator.go similarity index 100% rename from structure/20_decorator/decorator.go rename to structure/06_decorator/decorator.go diff --git a/structure/20_decorator/decorator_test.go b/structure/06_decorator/decorator_test.go similarity index 100% rename from structure/20_decorator/decorator_test.go rename to structure/06_decorator/decorator_test.go diff --git a/structure/09_proxy/README.md b/structure/07_proxy/README.md similarity index 100% rename from structure/09_proxy/README.md rename to structure/07_proxy/README.md diff --git a/structure/09_proxy/proxy.go b/structure/07_proxy/proxy.go similarity index 100% rename from structure/09_proxy/proxy.go rename to structure/07_proxy/proxy.go diff --git a/structure/09_proxy/proxy_test.go b/structure/07_proxy/proxy_test.go similarity index 100% rename from structure/09_proxy/proxy_test.go rename to structure/07_proxy/proxy_test.go