Struct duplicate_destroyer::Config
source · pub struct Config {
pub minimum_size: Option<u64>,
pub num_threads: Option<usize>,
pub progress_indicator: Option<Rc<RefCell<dyn ProgressIndicator>>>,
pub progress_multiline: Option<Rc<RefCell<dyn ProgressMultiline>>>,
}Expand description
Stores all configuration of Duplicate Destroyer
Fields§
§minimum_size: Option<u64>Minimum size of elements in DuplicateObjects returned. [default = 100]
This option has almost no bearing on the speed of Duplicate Destroyer, only on the output
size. The DuDe calculates checksums of files smaller than minimum_size, since the larger
directories might be composed of these smaller files and if we disregarded them, we could
lose some small but important data.
num_threads: Option<usize>Number of threads spawned for calculating the checksums of files [default = 0]
progress_indicator: Option<Rc<RefCell<dyn ProgressIndicator>>>Simple progress indicator.
To add a progress indicator to the DuDe, set to a trait object implementing the
ProgressIndicator trait.
[default = NoProgressIndicator]
progress_multiline: Option<Rc<RefCell<dyn ProgressMultiline>>>Multiline progress indicator.
To add a progress indicator for indicating the progress of duplicate file search add a
trait object implementing the
ProgressMultiline trait.
[default = NoProgressMultiline]
Implementations§
source§impl Config
impl Config
sourcepub fn set_minimum_size(&mut self, min_size: u64)
pub fn set_minimum_size(&mut self, min_size: u64)
Set minimum_size
sourcepub fn get_minimum_size(&self) -> u64
pub fn get_minimum_size(&self) -> u64
Get minimum_size
sourcepub fn set_num_threads(&mut self, num_threads: usize)
pub fn set_num_threads(&mut self, num_threads: usize)
Set num_threads
sourcepub fn get_num_threads(&self) -> usize
pub fn get_num_threads(&self) -> usize
Get num_threads