Asynchronously calls a completion callback with all data, upload, and download tasks in a session.
- iOS 7.0+
- macOS 10.9+
- tvOS 9.0+
- watchOS 2.0+
The completion handler to call with the list of tasks. This handler is executed on the delegate queue.
The returned arrays contain any tasks that you have created within the session, not including any tasks that have been invalidated after completing, failing, or being cancelled.