bytefetch 0.2.0

A Rust library that makes HTTP file downloads easier to implement.
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
use std::{sync::Arc, time::Duration};

use uuid::Uuid;

use crate::DownloadManager;

impl DownloadManager {
    pub fn on_progress<F>(&self, uuid: Uuid, callback: F, interval: Duration)
    where
        for<'a> F: Fn(u64) + Send + 'a,
    {
        let downloader = Arc::clone(self.downloads.get(&uuid).unwrap());
    }
}