ProgressReporter

Trait ProgressReporter 

Source
pub trait ProgressReporter: Send + Sync {
    // Required methods
    fn start(&self, total: u64, message: &str);
    fn update(&self, current: u64, message: Option<&str>);
    fn finish(&self, message: &str);
    fn error(&self, message: &str);
    fn warning(&self, message: &str);
    fn is_enabled(&self) -> bool;
}
Expand description

Trait for progress reporting implementations

Required Methods§

Source

fn start(&self, total: u64, message: &str)

Start a new progress bar/indicator

Source

fn update(&self, current: u64, message: Option<&str>)

Update progress

Source

fn finish(&self, message: &str)

Finish progress reporting

Source

fn error(&self, message: &str)

Report an error

Source

fn warning(&self, message: &str)

Report a warning

Source

fn is_enabled(&self) -> bool

Check if progress reporting is enabled

Implementors§