Archive

Trait Archive 

Source
pub trait Archive {
    // Required methods
    fn contains(&mut self, file: String) -> Result<bool, ArchiverError>;
    fn extract(&mut self, destination: &Path) -> Result<(), ArchiverError>;
    fn extract_single(
        &mut self,
        target: &Path,
        file: String,
    ) -> Result<(), ArchiverError>;
    fn files(&mut self) -> Result<Vec<String>, ArchiverError>;
    fn walk(
        &mut self,
        f: Box<dyn Fn(String) -> Option<String>>,
    ) -> Result<(), ArchiverError>;
}

Required Methods§

Source

fn contains(&mut self, file: String) -> Result<bool, ArchiverError>

Source

fn extract(&mut self, destination: &Path) -> Result<(), ArchiverError>

Source

fn extract_single( &mut self, target: &Path, file: String, ) -> Result<(), ArchiverError>

Source

fn files(&mut self) -> Result<Vec<String>, ArchiverError>

Source

fn walk( &mut self, f: Box<dyn Fn(String) -> Option<String>>, ) -> Result<(), ArchiverError>

Implementors§

Source§

impl<R: Read + Seek> Archive for Zip<R>

Source§

impl<R: Read> Archive for Tar<R>