Client for downloading an object.
More...
|
int | download_client_init (struct download_client *client, download_client_callback_t callback) |
| Initialize the download client.
|
|
int | download_client_set_host (struct download_client *client, const char *host, const struct download_client_cfg *config) |
| Set a target hostname.
|
|
int | download_client_start (struct download_client *client, const char *file, size_t from) |
| Download a file.
|
|
int | download_client_file_size_get (struct download_client *client, size_t *size) |
| Retrieve the size of the file being downloaded, in bytes.
|
|
int | download_client_downloaded_size_get (struct download_client *client, size_t *size) |
| Retrieve the number of bytes downloaded so far.
|
|
int | download_client_disconnect (struct download_client *client) |
| Initiate disconnection.
|
|
int | download_client_get (struct download_client *client, const char *host, const struct download_client_cfg *config, const char *file, size_t from) |
| Download a file asynchronously.
|
|
Client for downloading an object.
The download client provides APIs for:
- connecting to a remote server,
- downloading an object from the server,
- disconnecting from the server,
- receiving asynchronous event notifications on the download status.