摘要: 1.装饰者模式原理 1) 装饰者模式就像打包一个快递 主体:比如:陶瓷、衣服 (Component) // 被装饰者 包装:比如:报纸填充、塑料泡沫、纸板、木板(Decorator) 2) Component 主体:比如类似前面的 Drink 3) ConcreteComponent 和 Decor 阅读全文
posted @ 2021-12-29 17:13 周无极 阅读(41) 评论(0) 推荐(0) 编辑