Struct prodash::progress::Log [−][src]
pub struct Log { /* fields omitted */ }
A Progress
implementation which displays progress as it happens without the use of a renderer.
Note that this incurs considerable performance cost as each progress calls ends up getting the system time to see if progress information should actually be emitted.
Implementations
Trait Implementations
impl Progress for Log
[src]
impl Progress for Log
[src]type SubProgress = Log
type SubProgress = Log
The type of progress returned by add_child()
.
fn add_child(&mut self, name: impl Into<String>) -> Self::SubProgress
[src]
fn add_child(&mut self, name: impl Into<String>) -> Self::SubProgress
[src]Adds a new child, whose parent is this instance, with the given name. Read more
fn init(&mut self, max: Option<usize>, unit: Option<Unit>)
[src]
fn init(&mut self, max: Option<usize>, unit: Option<Unit>)
[src]Initialize the Item for receiving progress information. Read more
fn set(&mut self, step: usize)
[src]
fn set(&mut self, step: usize)
[src]Set the current progress to the given step
. The cost of this call is negligible,
making manual throttling not necessary. Read more
fn max(&self) -> Option<usize>
[src]
fn max(&self) -> Option<usize>
[src]Returns the maximum about of items we expect, as provided with the init(…)
call
fn inc_by(&mut self, step: usize)
[src]
fn inc_by(&mut self, step: usize)
[src]Increment the current progress to the given step
.
The cost of this call is negligible, making manual throttling not necessary. Read more
fn set_name(&mut self, name: impl Into<String>)
[src]
fn set_name(&mut self, name: impl Into<String>)
[src]Set the name of the instance, altering the value given when crating it with add_child(…)
The progress is allowed to discard it. Read more
fn name(&self) -> Option<String>
[src]
fn name(&self) -> Option<String>
[src]Get the name of the instance as given when creating it with add_child(…)
The progress is allowed to not be named, thus there is no guarantee that a previously set names ‘sticks’. Read more
fn message(&mut self, level: MessageLevel, message: impl Into<String>)
[src]
fn message(&mut self, level: MessageLevel, message: impl Into<String>)
[src]Create a message
of the given level
and store it with the progress tree. Read more
fn inc(&mut self)
[src]
fn inc(&mut self)
[src]Increment the current progress to the given 1. The cost of this call is negligible, making manual throttling not necessary. Read more
fn info(&mut self, message: impl Into<String>)
[src]
fn info(&mut self, message: impl Into<String>)
[src]Create a message providing additional information about the progress thus far.
fn done(&mut self, message: impl Into<String>)
[src]
fn done(&mut self, message: impl Into<String>)
[src]Create a message indicating the task is done successfully
fn show_throughput(&mut self, start: Instant)
[src]
fn show_throughput(&mut self, start: Instant)
[src]A shorthand to print throughput information
fn show_throughput_with(&mut self, start: Instant, step: Step, unit: Unit)
[src]
fn show_throughput_with(&mut self, start: Instant, step: Step, unit: Unit)
[src]A shorthand to print throughput information, with the given step and unit