pub struct Strategy {} use std::path::PathBuf; use crate::file_handler::{FileType, FileHandlerStrategy}; impl FileHandlerStrategy for Strategy { fn is(&self, path: &PathBuf) -> bool { !path.is_dir() } fn identify(&self) -> FileType { FileType::File } fn can_handle(&self, path: &PathBuf) -> bool { !path.is_dir() } fn handle(&self, path: &PathBuf) { println!("Should copy {}", path.display()) } }