Pulp 1.88.0
Cross-platform audio plugin framework
Loading...
Searching...
No Matches
pulp::runtime::DownloadRequest Struct Reference

#include <model_download.hpp>

Public Attributes

std::string url
 http(s)://… (resolve hf:// first).
std::filesystem::path dest
 Final destination path.
std::string expected_sha256
 Hex digest the finished file must match.
std::vector< HttpHeader > headers
 Extra request headers (e.g. Authorization).
bool resume = true
 Resume from a prior partial <dest>.part via Range.
int timeout_seconds = 0
 0 ⇒ a sensible library default.
bool allow_unverified = false
 An empty expected_sha256 means nothing can vouch for the bytes, so the download is refused (DownloadResult::unverified) unless the caller opts in here.

Member Data Documentation

◆ allow_unverified

bool pulp::runtime::DownloadRequest::allow_unverified = false

An empty expected_sha256 means nothing can vouch for the bytes, so the download is refused (DownloadResult::unverified) unless the caller opts in here.

Opting in still records the digest the transfer produced.

◆ dest

std::filesystem::path pulp::runtime::DownloadRequest::dest

Final destination path.

◆ expected_sha256

std::string pulp::runtime::DownloadRequest::expected_sha256

Hex digest the finished file must match.

◆ headers

std::vector<HttpHeader> pulp::runtime::DownloadRequest::headers

Extra request headers (e.g. Authorization).

◆ resume

bool pulp::runtime::DownloadRequest::resume = true

Resume from a prior partial <dest>.part via Range.

◆ timeout_seconds

int pulp::runtime::DownloadRequest::timeout_seconds = 0

0 ⇒ a sensible library default.

◆ url

std::string pulp::runtime::DownloadRequest::url

http(s)://… (resolve hf:// first).


The documentation for this struct was generated from the following file: