pub struct ManifestLeaf { /* private fields */ }Implementations§
Source§impl ManifestLeaf
impl ManifestLeaf
Sourcepub fn new(
entries: Vec<ManifestObject>,
) -> Result<ManifestLeaf, ManifestNodeError>
pub fn new( entries: Vec<ManifestObject>, ) -> Result<ManifestLeaf, ManifestNodeError>
Build a leaf, sorting entries into canonical key order.
Returns ManifestNodeError::DuplicateObjectKey if two entries share a
(kind, hash) key, even when their declared sizes agree: the canonical
form names each object exactly once.
pub fn entries(&self) -> &[ManifestObject]
pub fn object_count(&self) -> u64
Sourcepub fn decoded_bytes(&self) -> Option<u64>
pub fn decoded_bytes(&self) -> Option<u64>
Total decoded bytes named by this leaf, or None on u64 overflow.
Trait Implementations§
Source§impl Clone for ManifestLeaf
impl Clone for ManifestLeaf
Source§fn clone(&self) -> ManifestLeaf
fn clone(&self) -> ManifestLeaf
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 ManifestLeaf
impl Debug for ManifestLeaf
impl Eq for ManifestLeaf
Source§impl PartialEq for ManifestLeaf
impl PartialEq for ManifestLeaf
impl StructuralPartialEq for ManifestLeaf
Auto Trait Implementations§
impl Freeze for ManifestLeaf
impl RefUnwindSafe for ManifestLeaf
impl Send for ManifestLeaf
impl Sync for ManifestLeaf
impl Unpin for ManifestLeaf
impl UnsafeUnpin for ManifestLeaf
impl UnwindSafe for ManifestLeaf
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