Download files in queue in Android

前端 未结 3 1234
再見小時候
再見小時候 2021-01-01 08:05

How do I download multiple files in a queue one by one! I\'m using this as a sample code, since. I would be passing the URLs to download in Strings from my local DB dynamic

3条回答
  •  南笙
    南笙 (楼主)
    2021-01-01 08:44

    What's the best way to implement a download queue in Android?

    Use an IntentService. It supplies the queue and the background thread for you, so all you have to do is put your download logic in onHandleIntent(). See here for a sample project demonstrating this.

提交回复
热议问题