pub struct ObjectChecksum {
pub algorithm: ChecksumAlgorithm,
pub value: String,
}Expand description
An encoded checksum paired with its algorithm.
Fields§
§algorithm: ChecksumAlgorithmAlgorithm used to calculate the checksum.
value: StringProtocol-encoded checksum value.
Implementations§
Source§impl ObjectChecksum
impl ObjectChecksum
Sourcepub fn new(
algorithm: ChecksumAlgorithm,
value: impl Into<String>,
) -> Result<Self>
pub fn new( algorithm: ChecksumAlgorithm, value: impl Into<String>, ) -> Result<Self>
Build a checksum while rejecting an ambiguous empty value.
Sourcepub fn new_persisted(
algorithm: ChecksumAlgorithm,
value: impl Into<String>,
) -> Result<Self>
pub fn new_persisted( algorithm: ChecksumAlgorithm, value: impl Into<String>, ) -> Result<Self>
Build a checksum reported by a metadata read.
Multipart SHA and CRC checksums use the S3 composite form
<base64-digest>-<part-count>, which is not valid as a precomputed
full-object write checksum.
Trait Implementations§
Source§impl Clone for ObjectChecksum
impl Clone for ObjectChecksum
Source§fn clone(&self) -> ObjectChecksum
fn clone(&self) -> ObjectChecksum
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 ObjectChecksum
impl Debug for ObjectChecksum
impl Eq for ObjectChecksum
Source§impl PartialEq for ObjectChecksum
impl PartialEq for ObjectChecksum
impl StructuralPartialEq for ObjectChecksum
Auto Trait Implementations§
impl Freeze for ObjectChecksum
impl RefUnwindSafe for ObjectChecksum
impl Send for ObjectChecksum
impl Sync for ObjectChecksum
impl Unpin for ObjectChecksum
impl UnsafeUnpin for ObjectChecksum
impl UnwindSafe for ObjectChecksum
Blanket Implementations§
Source§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
Source§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
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