pub struct WindowsFetchDataProgress { /* private fields */ }Expand description
One provider progress sample for a pending CFAPI transfer.
Implementations§
Source§impl WindowsFetchDataProgress
impl WindowsFetchDataProgress
Sourcepub fn new(total: u64, completed: u64) -> Result<Self>
pub fn new(total: u64, completed: u64) -> Result<Self>
Creates a progress sample. Zero-sized work is represented as (0, 0).
§Errors
Returns an error when validation fails or an underlying backend, store, or platform operation fails.
Sourcepub const fn as_cfapi(self) -> (i64, i64)
pub const fn as_cfapi(self) -> (i64, i64)
Returns the signed values accepted by CfReportProviderProgress.
Sourcepub fn advance_from(self, previous: Self) -> Result<Self>
pub fn advance_from(self, previous: Self) -> Result<Self>
Validates a new sample against a previous sample for the same transfer.
§Errors
Returns an error when validation fails or an underlying backend, store, or platform operation fails.
Trait Implementations§
Source§impl Clone for WindowsFetchDataProgress
impl Clone for WindowsFetchDataProgress
Source§fn clone(&self) -> WindowsFetchDataProgress
fn clone(&self) -> WindowsFetchDataProgress
Returns a duplicate of the value. Read more
1.0.0 · 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 WindowsFetchDataProgress
impl Debug for WindowsFetchDataProgress
Source§impl Hash for WindowsFetchDataProgress
impl Hash for WindowsFetchDataProgress
Source§impl PartialEq for WindowsFetchDataProgress
impl PartialEq for WindowsFetchDataProgress
impl Copy for WindowsFetchDataProgress
impl Eq for WindowsFetchDataProgress
impl StructuralPartialEq for WindowsFetchDataProgress
Auto Trait Implementations§
impl Freeze for WindowsFetchDataProgress
impl RefUnwindSafe for WindowsFetchDataProgress
impl Send for WindowsFetchDataProgress
impl Sync for WindowsFetchDataProgress
impl Unpin for WindowsFetchDataProgress
impl UnwindSafe for WindowsFetchDataProgress
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