If I have a large file download and the application moves to the background, is there a way to preserve the download execution features?
I know that beginBackgroundTaskWithExpirationHandler: is called when the application moves to the background, and I can run my task there, but I do not want to start a new task, I want to complete the old task. It can be solved with beginBackgroundTaskWithExpirationHandler: but for this I need to pause the download and resume it from the right place, which is just plain stupid.
Ideally, I want me to load the download function with an expiration handler, so my download function continues to run for the allowed time after the application has been moved to the background.
source share