3 use std::path::PathBuf;
5 use crate::file_handler::{File, FileType, FileHandlerStrategy};
7 impl FileHandlerStrategy for Strategy {
8 fn is(&self, path: &PathBuf) -> bool {
9 if let Some(extension) = path.extension() {
10 return !path.is_dir() && extension == "gmi"
15 fn identify(&self) -> FileType {
19 fn can_handle(&self, file_type: &FileType) -> bool {
21 FileType::Gemini => true,
26 fn handle(&self, file: &File) {
27 println!("Should parse and copy {}", file.path.display())