pub trait ProgressIteratorExt: Sized {
// Required methods
fn progress(self) -> ProgressIter<Self> ⓘ;
fn progress_with_name(
self,
name: impl Into<CompactString>,
) -> ProgressIter<Self> ⓘ;
fn progress_with(self, progress: Progress) -> ProgressIter<Self> ⓘ;
fn progress_in(self, stack: &ProgressStack) -> ProgressIter<Self> ⓘ;
fn type_from_size_hint(&self) -> (ProgressType, u64);
}Expand description
Extension trait to easily attach progress tracking to any Iterator.
Required Methods§
Sourcefn progress(self) -> ProgressIter<Self> ⓘ
fn progress(self) -> ProgressIter<Self> ⓘ
Wraps the iterator in a Progress.
Automatically detects if the iterator has a known size (via size_hint) to
choose between a Bar or Spinner.
Sourcefn progress_with_name(
self,
name: impl Into<CompactString>,
) -> ProgressIter<Self> ⓘ
fn progress_with_name( self, name: impl Into<CompactString>, ) -> ProgressIter<Self> ⓘ
Wraps the iterator in a Progress with a specific name.
Sourcefn progress_with(self, progress: Progress) -> ProgressIter<Self> ⓘ
fn progress_with(self, progress: Progress) -> ProgressIter<Self> ⓘ
Wraps the iterator using an existing Progress instance.
Sourcefn progress_in(self, stack: &ProgressStack) -> ProgressIter<Self> ⓘ
fn progress_in(self, stack: &ProgressStack) -> ProgressIter<Self> ⓘ
Creates a new Progress attached to the given ProgressStack and wraps the iterator.
Sourcefn type_from_size_hint(&self) -> (ProgressType, u64)
fn type_from_size_hint(&self) -> (ProgressType, u64)
Internal helper to determine progress type and total from size_hint.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.