termal_core 5.0.0

This library contains implementation for the termal library
Documentation
use std::time::Duration;

/// Decides how to display progress.
pub trait ProgressFormatter {
    /// Start the progress. This may not be called.
    fn start(&mut self, task: &str, info: &str);

    /// Update the progress.
    fn update(
        &mut self,
        done: Option<f32>,
        task: &str,
        info: &str,
        time: Duration,
    );

    /// Finish the progress.
    fn finish(&mut self, task: &str, info: &str, time: Duration);

    /// The job failed with the given error.
    fn fail(
        &mut self,
        done: Option<f32>,
        task: &str,
        info: &str,
        time: Duration,
        err: &str,
    );
}