mirror of
https://github.com/CyC2018/Interview-Notebook.git
synced 2026-10-31 19:13:42 +00:00
Update 设计模式 - 外观.md
补充实现代码中的客户端调用示例,文字校对参考文献中的标点符号。
This commit is contained in:
+7
-1
@@ -48,6 +48,12 @@ public class Client {
|
||||
}
|
||||
```
|
||||
|
||||
```text
|
||||
turnOnTV()
|
||||
setCD( a movie )
|
||||
startWatching()
|
||||
```
|
||||
|
||||
### 设计原则
|
||||
|
||||
最少知识原则:只和你的密友谈话。也就是说客户对象所需要交互的对象应当尽可能少。
|
||||
@@ -55,4 +61,4 @@ public class Client {
|
||||
## 参考资料
|
||||
|
||||
- 弗里曼. Head First 设计模式 [M]. 中国电力出版社, 2007.
|
||||
- Gamma E. 设计模式: 可复用面向对象软件的基础 [M]. 机械工业出版社, 2007.
|
||||
- Gamma E. 设计模式:可复用面向对象软件的基础 [M]. 机械工业出版社, 2007.
|
||||
|
||||
Reference in New Issue
Block a user