今天就学习课程吧!
今天就开通帐号,24,700 门业界名师课程任您挑!
The Command pattern
- [Instructor] With the command pattern, commands are objects that contain all of the data necessary to execute a specific action on the client. Think about boxes of furniture that need to be assembled. Each box contains all of the parts necessary along with the instructions on how to assemble that piece of furniture. A professional installer can open a box, follow the instructions and use the materials to assemble the furniture. The installer doesn't need to know how to build each piece of furniture. It doesn't matter to them because the instructions of how to build the furniture come with the box. The installer can open a box, follow the instructions and assemble the furniture; and then they can move on to the next box. In this analogy I like to think of each furniture package as a command. They are all different, they contain different parts and different instructions. The installer can execute a command. They can…
随堂练习,边学边练
下载课堂讲义。学练结合,紧跟进度,轻松巩固知识。
内容
-
-
-
-
-
-
(已锁定)
Chain of responsibility4 分钟 42 秒
-
(已锁定)
Implementing the storage class6 分钟 22 秒
-
(已锁定)
The Command pattern4 分钟 47 秒
-
(已锁定)
Implementing commands4 分钟 59 秒
-
(已锁定)
Improving the conductor6 分钟 38 秒
-
(已锁定)
The Iterator pattern4 分钟 5 秒
-
(已锁定)
Implementing iterators4 分钟 59 秒
-
(已锁定)
The Observer pattern4 分钟 19 秒
-
(已锁定)
Implementing observers2 分钟 48 秒
-
(已锁定)
The Strategy pattern4 分钟 25 秒
-
(已锁定)
Implementing strategies9 分钟 36 秒
-
(已锁定)
-