官术网_书友最值得收藏!

Life Cycle and Error Handling

Now that we have an application using coroutines in order to do network requests, it's time to add new features to it while putting into practice new concepts and improving the user experience.

In this chapter, we will start by taking a closer look at two types of asynchronous tasks: Job and Deferred. We will talk about their similarities and their differences, taking a closer look at their life cycle. We will also cover how to calculate their current state and what to expect in each state. Then, we will improve our RSS reader by having it fetch news concurrently from many news outlets and using the newly introduced topics to handle exceptions when a feed can't be reached.

Some of the topics we will cover during this chapter are as listed:

  • Jobs and their use cases
  • Life cycle of Job and Deferred
  • Use cases for Deferred
  • What to expect with each status of a Job
  • How to calculate the current status of a Job
  • How to handle exceptions
主站蜘蛛池模板: 元氏县| 宜兰县| 平罗县| 车险| 达孜县| 平舆县| 林芝县| 图木舒克市| 蓝田县| 文登市| 高阳县| 绥化市| 平江县| 合肥市| 威远县| 花莲县| 辽源市| 莱州市| 黄冈市| 财经| 安达市| 岳西县| 宁阳县| 丹江口市| 恩施市| 西丰县| 涿鹿县| 子洲县| 松原市| 镇原县| 湘潭市| 土默特右旗| 长海县| 桐梓县| 高唐县| 阜平县| 淄博市| 台东县| 普宁市| 鲜城| 松溪县|