pub struct ProgressStats {
pub total: u64,
pub completed: u64,
pub failed: u64,
pub in_progress: u64,
pub start_time: Instant,
pub bytes_processed: u64,
}Expand description
Progress statistics for a single operation
Fields§
§total: u64Total items to process
completed: u64Items completed successfully
failed: u64Items that failed
in_progress: u64Items currently in progress
start_time: InstantStart time
bytes_processed: u64Bytes processed (if applicable)
Implementations§
Source§impl ProgressStats
impl ProgressStats
Sourcepub fn items_per_second(&self) -> f64
pub fn items_per_second(&self) -> f64
Calculate throughput (items per second)
Sourcepub fn bytes_per_second(&self) -> f64
pub fn bytes_per_second(&self) -> f64
Calculate bytes throughput
Sourcepub fn estimated_remaining(&self) -> Duration
pub fn estimated_remaining(&self) -> Duration
Estimate time remaining
Sourcepub fn percent_complete(&self) -> f64
pub fn percent_complete(&self) -> f64
Get completion percentage
Trait Implementations§
Source§impl Clone for ProgressStats
impl Clone for ProgressStats
Source§fn clone(&self) -> ProgressStats
fn clone(&self) -> ProgressStats
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for ProgressStats
impl Debug for ProgressStats
Auto Trait Implementations§
impl Freeze for ProgressStats
impl RefUnwindSafe for ProgressStats
impl Send for ProgressStats
impl Sync for ProgressStats
impl Unpin for ProgressStats
impl UnsafeUnpin for ProgressStats
impl UnwindSafe for ProgressStats
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
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 moreSource§impl<T> Pointable for T
impl<T> Pointable for T
impl<T> Read<Exclusive, BecauseExclusive> for Twhere
T: ?Sized,
Source§impl<R, P> ReadPrimitive<R> for P
impl<R, P> ReadPrimitive<R> for P
Source§fn read_from_little_endian(read: &mut R) -> Result<Self, Error>
fn read_from_little_endian(read: &mut R) -> Result<Self, Error>
Read this value from the supplied reader. Same as
ReadEndian::read_from_little_endian().