Hi,
I'm trying to better understand how BackgroundTasks work.
From what I understand the application has two interesting states: Foreground and Background. Once the app is put in background state, all executions are paused. Once back in the foreground these executions are resumed from the moment they stopped.
Assuming I have a long task to perform that starts when the app is in the foreground, is it possible that it can pick up where it left off once the app is relaunched for a BackgroundTask?
All the indications given by Apple mention use cases where the app is awakened to do other tasks from 0, but I would like to continue something that is already in progress!
I'm having a hard time experiencing this behavior because to trigger the
e -l objc -- (void)[[BGTaskScheduler sharedScheduler] _simulateLaunchForTaskWithIdentifier:@"TASK_IDENTIFIER"]
command i have to resume the app as mentioned here.
So at that point I'm no longer sure if my process is continuing because I actually have the app in the foreground or it would run with the app in the background as well
thx