#[derive(Clone, Debug)]
pub enum InputType {
    Path(String),
    StdIn,
}

#[derive(Clone, Debug)]
pub enum InputFormat {
    Extension(String),
    Auto,
}

#[derive(Clone, Debug)]
pub struct Input {
    pub input: InputType,
    pub format: InputFormat,
}

impl From<&str> for Input {
    fn from(path: &str) -> Self {
        Input {
            input: InputType::Path(path.to_string()),
            format: InputFormat::Auto,
        }
    }
}

impl From<&String> for Input {
    fn from(path: &String) -> Self {
        Input {
            input: InputType::Path(path.to_string()),
            format: InputFormat::Auto,
        }
    }
}

impl From<String> for Input {
    fn from(path: String) -> Self {
        Input {
            input: InputType::Path(path),
            format: InputFormat::Auto,
        }
    }
}
