- Hands-On Reactive Programming with Python
- Romain Picard
- 142字
- 2021-06-24 18:25:14
Reactivity diagrams of an echo example
We will complete this tour of the reactivity diagrams by writing the echo example. Its diagram is shown in the following figure:
Figure 1.19: The echo app reactivity diagram
This simple diagram should allow any developer to understand what is going on, provided that he knows that it applies to each item emitted on the argv input observable. First, the input observable is created from the argv variable. Then each item is capitalized with the map operator. Finally, each event type (item, completion, or error) is printed. Note that the content of each element is not a copy of the code, but a small description of what it does. The echo example was quite simple, but in a real application you want to document the behavior with reactivity diagrams, not duplicate the code on a diagram.
推薦閱讀
- 30天自制操作系統(tǒng)
- Social Media Mining with R
- Red Hat Enterprise Linux 8系統(tǒng)管理實(shí)戰(zhàn)
- 嵌入式Linux系統(tǒng)開發(fā):基于Yocto Project
- 嵌入式應(yīng)用程序設(shè)計(jì)綜合教程(微課版)
- Extending Bootstrap
- 深入理解eBPF與可觀測性
- 無蘋果不生活 The New iPad隨身寶典
- 計(jì)算機(jī)應(yīng)用基礎(chǔ)(Windows 7+Office 2016)
- 精解Windows 10
- Learning BeagleBone
- 鴻蒙操作系統(tǒng)設(shè)計(jì)原理與架構(gòu)
- iOS 10 開發(fā)指南
- 鴻蒙HarmonyOS手機(jī)應(yīng)用開發(fā)實(shí)戰(zhàn)
- Drupal 7 Cookbook