Packer

Trait Packer 

Source
pub trait Packer: Send {
    // Required methods
    fn pack_name(&self) -> &'static str;
    fn do_pack(
        &self,
        log_file: File,
        log_file_path: &str,
    ) -> Result<bool, LogError>;

    // Provided method
    fn retry(&self) -> i32 { ... }
}
Expand description

.zip or .lz4 or any one packer

Required Methods§

Source

fn pack_name(&self) -> &'static str

Source

fn do_pack(&self, log_file: File, log_file_path: &str) -> Result<bool, LogError>

Provided Methods§

Source

fn retry(&self) -> i32

default 0 is not retry pack. if retry > 0 ,it will trying rePack

Implementors§