A Boolean value that determines whether background tasks can be scheduled at the discretion of the system for optimal performance.
- iOS 7.0+
- macOS 10.10+
- tvOS 7.0+
- watchOS 2.0+
For configuration objects created using the
background(with method, use this property to give the system control over when transfers should occur. This property is ignored for configuration objects created using other methods.
When transferring large amounts of data, you are encouraged to set the value of this property to
true. Doing so lets the system schedule those transfers at times that are more optimal for the device. For example, the system might delay transferring large files until the device is plugged in and connected to the network via Wi-Fi. The default value of this property is
The session object applies the value of this property only to transfers that your app starts while it is in the foreground. For transfers started while your app is in the background, the system always starts transfers at its discretion—in other words, the system assumes this property is
true and ignores any value you specified.