Android AsyncTask inside AsyncTask

前端 未结 3 751
野趣味
野趣味 2020-12-18 05:44

So, I\'m working on a barcode decoder, which once we have the barcode goes to multiples API over the internet to decode what was just scanned. The thing is that I have to li

3条回答
  •  南方客
    南方客 (楼主)
    2020-12-18 06:03

    You can go for another approach if you are facing often a situation like this. That is to merge requests and operations inside of runnables/callables and to manage them separately within say a queue for instance. Here is a nice approach. http://ugiagonzalez.com/2012/07/02/theres-life-after-asynctasks-in-android/

提交回复
热议问题