pub struct TransferHandle { /* private fields */ }Expand description
Handle for tracking and controlling a single transfer.
Implementations§
Source§impl TransferHandle
impl TransferHandle
Sourcepub fn new(total_bytes: u64) -> TransferHandle
pub fn new(total_bytes: u64) -> TransferHandle
Sourcepub async fn progress(&self) -> TransferProgress
pub async fn progress(&self) -> TransferProgress
Sourcepub async fn update_progress(&self, bytes_delta: u64, chunks_delta: u32)
pub async fn update_progress(&self, bytes_delta: u64, chunks_delta: u32)
Sourcepub async fn set_total_bytes(&self, total_bytes: u64)
pub async fn set_total_bytes(&self, total_bytes: u64)
Sourcepub fn is_cancelled(&self) -> bool
pub fn is_cancelled(&self) -> bool
Trait Implementations§
Source§impl Clone for TransferHandle
impl Clone for TransferHandle
Source§fn clone(&self) -> TransferHandle
fn clone(&self) -> TransferHandle
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 moreAuto Trait Implementations§
impl Freeze for TransferHandle
impl !RefUnwindSafe for TransferHandle
impl Send for TransferHandle
impl Sync for TransferHandle
impl Unpin for TransferHandle
impl !UnwindSafe for TransferHandle
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