pub struct PartialDownloadStateInner {
pub url: Option<Url>,
pub etag: Option<Option<Arc<str>>>,
pub last_modified: Option<Option<Arc<str>>>,
pub config: Option<PartialConfig>,
pub size: Option<u64>,
pub elapsed: Option<Duration>,
}Fields§
§url: Option<Url>§etag: Option<Option<Arc<str>>>§last_modified: Option<Option<Arc<str>>>§config: Option<PartialConfig>§size: Option<u64>Total file size recorded at save time, compared against the server
UrlInfo.size during resume validation.
An older .fd written without this field reads back as None, which
makes validate fail and safely fall back to a full re-download.
elapsed: Option<Duration>Total active download time accumulated across all resume runs.
Persisted as a human-readable string (e.g. "1h 30m 2s") via
humantime_serde, so the .fd file stays easy to inspect and edit by
hand. A zero elapsed is omitted from the file, and a missing elapsed
field on load is tolerated (treated as zero). A resumed download
continues this clock instead of restarting it from zero; the progress
reporter folds it into its average-speed calculation, giving a speed that
spans the whole download session rather than only the current run.
Trait Implementations§
Source§impl Clone for PartialDownloadStateInner
impl Clone for PartialDownloadStateInner
Source§fn clone(&self) -> PartialDownloadStateInner
fn clone(&self) -> PartialDownloadStateInner
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more