Holds options that can be specified when starting a new download with downloadToFile(). More...
Public Member Functions | |
auto | withExtraHeaders (String value) const |
Specifies headers to add to the request. | |
auto | withSharedContainer (String value) const |
On iOS, specifies the container where the downloaded file will be stored. | |
auto | withListener (DownloadTaskListener *value) const |
Specifies an observer for the download task. | |
auto | withUsePost (bool value) const |
Specifies whether a post command should be used. | |
Public Attributes | |
String | extraHeaders |
String | sharedContainer |
DownloadTaskListener * | listener = nullptr |
bool | usePost = false |
Holds options that can be specified when starting a new download with downloadToFile().
|
nodiscard |
Specifies headers to add to the request.
References extraHeaders.
|
nodiscard |
On iOS, specifies the container where the downloaded file will be stored.
If you initiate a download task from inside an app extension on iOS, you must supply this option.
This is currently unused on other platforms.
References sharedContainer.
|
nodiscard |
Specifies an observer for the download task.
References listener.
|
nodiscard |
Specifies whether a post command should be used.
References usePost.
String URL::DownloadTaskOptions::extraHeaders |
Referenced by withExtraHeaders().
String URL::DownloadTaskOptions::sharedContainer |
Referenced by withSharedContainer().
DownloadTaskListener* URL::DownloadTaskOptions::listener = nullptr |
Referenced by withListener().
bool URL::DownloadTaskOptions::usePost = false |
Referenced by withUsePost().