简体   繁体   中英

Long time downloading in iOS app

How many issues need to be considered carefully if a large of content need to be downloaded in an iOS app ?

Here are my known issues:

  1. Network , No limits for Wifi, but Apple has limit policy for cellular network. enter link description here
  2. Background execution. Apple introduced multitasking for several cases, but no for downloading large content background. Here is a good analysis .
  3. Newsstand provides good solution for this. But does that mean you need follow the Newsstand approach ? We do not want to build an newsstand type app.

What else issues do you think ? and what is the best solution for this sort of problem ?

I would lazy load only data as needed. When the user requests an area load revenant data. If you want to preload do it in the background. I have seen 1.6Gb apps with lots of videos, embedded in main bundle, but that was for sales app that needed to have all videos ready to go and could not assume any active network connection.

Download the data you need in a background thread while your app is running. If your app is terminated or suspended before you get all the data, resume where you left off the next time the app is running. There are a number of ways that you can do that; one good one is to break your data up into smaller chunks that can be downloaded sequentially.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM