This package allows you to configure and operate download sessions using either HTTP or HTTPS. You can perform basic download task operations such as adding or removing a task, query download information, and set download session listeners.
With this package, you can create a remote download session on another device in the ohos network so that it can download data for the local device without consuming local network and storage resources. The remote download sessions support both HTTP and HTTPS. You can also query and remove created sessions.
| 接口 | 说明 |
|---|---|
| IDownloadListener |
Provides callbacks to listen for download session status.
|
| 类 | 说明 |
|---|---|
| DownloadConfig |
Defines configuration of download sessions.
|
| DownloadConfig.Builder |
Provides
Builder objects of download configuration,
including methods to set parameters used to create a download session. |
| DownloadSession |
Defines an HTTP or HTTPS download session as a
DownloadSession object and provides management
interfaces, such as starting, pausing, resuming, and deleting a session, and querying session details. |
| DownloadSession.DownloadInfo |
Provides methods for obtaining download session information and status.
|