- Hands-On Reactive Programming with Python
- Romain Picard
- 188字
- 2021-06-24 18:25:22
Exploring Observables and Observers
In this chapter, we will go into detail on observables: how to create them, how to subscribe to them, how to handle their errors, and how to use them with AsyncIO. In the first part of this chapter, we will describe all of the possible ways to create observables, from existing objects, iterable objects, or custom code logic. Each time a new observable is needed, one of these methods is best for the situation.
In the second part of this chapter, we will explain another important notion of ReactiveX: hot and cold observables. Knowing whether an observable is hot or cold is the key to using it correctly. The third part of this chapter will cover the different ways to listen to an observable and how to deal with errors. Finally, the last part will illustrate how observables can cohabit with AsyncIO and how to bridge futures and observables. This is a frequent requirement when writing drivers based on AsyncIO packages.
The following topics will be covered in this chapter:
- Creating observables
- Hot and cold observables
- Subscription and disposal
- Error handling
- Observables and AsyncIO
- Implementing Cisco UCS Solutions
- 精通Linux內(nèi)核開發(fā)
- 嵌入式Linux系統(tǒng)開發(fā):基于Yocto Project
- Windows Phone 7.5 Data Cookbook
- Linux集群和自動(dòng)化運(yùn)維
- 循序漸進(jìn)學(xué)Docker
- 網(wǎng)絡(luò)操作系統(tǒng)管理與應(yīng)用(第三版)
- STM32庫(kù)開發(fā)實(shí)戰(zhàn)指南:基于STM32F4
- Joomla! 3 Template Essentials
- 計(jì)算機(jī)系統(tǒng):基于x86+Linux平臺(tái)
- AWS SysOps Cookbook
- iOS 10 開發(fā)指南
- UI設(shè)計(jì)手繪表現(xiàn)從入門到精通
- Android應(yīng)用性能優(yōu)化最佳實(shí)踐
- Linux內(nèi)核分析及應(yīng)用