Enum UploadProgress
pub enum UploadProgress {
Incomplete {
offset: u64,
},
Complete,
}Expand description
How far a resumable upload has progressed.
Both a chunk write and an offset query can observe that an upload is complete, so both
operations have the same two outcomes. Completion is relative to the backend handling the
operation: it means the session is terminal and the object is available through that backend’s
normal read methods. A backend that composes another backend must finish its own publication
work before returning UploadProgress::Complete.
Variants§
Incomplete
More bytes are expected. The client continues from offset.
This offset is authoritative and may be lower than the end of the chunk that was just written: backends can persist only a prefix and discard the remainder. It must remain below the session’s total length; once every byte has landed, the backend completes the upload or returns an error instead.
Complete
The session is terminal and the object is available through the backend’s normal reads.
This is an observable status rather than a one-time event. A later offset query can return
Complete again, for example when the response to the final chunk was lost.
Trait Implementations§
§impl Clone for UploadProgress
impl Clone for UploadProgress
§fn clone(&self) -> UploadProgress
fn clone(&self) -> UploadProgress
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreimpl Copy for UploadProgress
§impl Debug for UploadProgress
impl Debug for UploadProgress
impl Eq for UploadProgress
§impl PartialEq for UploadProgress
impl PartialEq for UploadProgress
impl StructuralPartialEq for UploadProgress
Auto Trait Implementations§
impl Freeze for UploadProgress
impl RefUnwindSafe for UploadProgress
impl Send for UploadProgress
impl Sync for UploadProgress
impl Unpin for UploadProgress
impl UnsafeUnpin for UploadProgress
impl UnwindSafe for UploadProgress
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
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,
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§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>
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>
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