use std::path::PathBuf;
#[derive(Debug, Clone)]
pub struct Item {
pub path: PathBuf,
pub bytes: u64,
}
#[derive(Debug, Clone)]
pub struct Plan {
pub items: Vec<Item>,
pub total_bytes: u64,
}
impl Plan {
pub fn new(items: Vec<Item>) -> Self {
let total_bytes = items.iter().map(|i| i.bytes).sum();
Self { items, total_bytes }
}
}