pub struct ProgressTracker { /* private fields */ }Expand description
Progress tracker for conform operations.
Implementations§
Source§impl ProgressTracker
impl ProgressTracker
Sourcepub fn set_stage(&self, stage: ProgressStage)
pub fn set_stage(&self, stage: ProgressStage)
Set the current stage.
Sourcepub fn stage(&self) -> ProgressStage
pub fn stage(&self) -> ProgressStage
Get the current stage.
Sourcepub fn set_total_items(&self, total: usize)
pub fn set_total_items(&self, total: usize)
Set total items.
Sourcepub fn set_current_item(&self, current: usize)
pub fn set_current_item(&self, current: usize)
Set current item.
Sourcepub fn increment_item(&self)
pub fn increment_item(&self)
Increment current item.
Sourcepub fn set_description(&self, desc: String)
pub fn set_description(&self, desc: String)
Set description.
Sourcepub fn percentage(&self) -> f64
pub fn percentage(&self) -> f64
Get current progress percentage.
Sourcepub fn info(&self) -> ProgressInfo
pub fn info(&self) -> ProgressInfo
Get current progress information.
Sourcepub fn set_bytes_processed(&self, bytes: u64)
pub fn set_bytes_processed(&self, bytes: u64)
Set bytes processed.
Sourcepub fn add_bytes_processed(&self, bytes: u64)
pub fn add_bytes_processed(&self, bytes: u64)
Add bytes processed.
Sourcepub fn set_total_bytes(&self, bytes: u64)
pub fn set_total_bytes(&self, bytes: u64)
Set total bytes.
Sourcepub fn bytes_processed(&self) -> u64
pub fn bytes_processed(&self) -> u64
Get bytes processed.
Sourcepub fn total_bytes(&self) -> u64
pub fn total_bytes(&self) -> u64
Get total bytes.
Trait Implementations§
Source§impl Clone for ProgressTracker
impl Clone for ProgressTracker
Auto Trait Implementations§
impl !RefUnwindSafe for ProgressTracker
impl !UnwindSafe for ProgressTracker
impl Freeze for ProgressTracker
impl Send for ProgressTracker
impl Sync for ProgressTracker
impl Unpin for ProgressTracker
impl UnsafeUnpin for ProgressTracker
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more