pub struct ZipSliceEntry<'a> { /* private fields */ }Expand description
Represents a single entry (file or directory) within a ZipSliceArchive.
It provides access to the raw compressed data of the entry.
Implementations§
Source§impl<'a> ZipSliceEntry<'a>
impl<'a> ZipSliceEntry<'a>
Sourcepub fn data(&self) -> &'a [u8] ⓘ
pub fn data(&self) -> &'a [u8] ⓘ
Returns the raw, compressed data of the entry as a byte slice.
Sourcepub fn claim_verifier(&self) -> ZipVerification
pub fn claim_verifier(&self) -> ZipVerification
Returns a verifier for the CRC and uncompressed size of the entry.
Useful when it’s more practical to oneshot decompress the data,
otherwise use ZipSliceEntry::verifying_reader to stream
decompression and verification.
Sourcepub fn verifying_reader<D>(&self, reader: D) -> ZipSliceVerifier<D> ⓘwhere
D: Read,
pub fn verifying_reader<D>(&self, reader: D) -> ZipSliceVerifier<D> ⓘwhere
D: Read,
Returns a reader that wraps a decompressor and verify the size and CRC of the decompressed data once finished.
Sourcepub fn compressed_data_range(&self) -> (u64, u64)
pub fn compressed_data_range(&self) -> (u64, u64)
Returns the byte range of the compressed data within the archive.
See ZipEntry::compressed_data_range for more details.
Sourcepub fn extra_fields(&self) -> ExtraFields<'_> ⓘ
pub fn extra_fields(&self) -> ExtraFields<'_> ⓘ
Returns an iterator over the extra fields from the local file header.
See ZipLocalFileHeader for more details.
Sourcepub fn file_path(&self) -> ZipFilePath<RawPath<'_>>
pub fn file_path(&self) -> ZipFilePath<RawPath<'_>>
Returns the file path from the local file header.
See ZipLocalFileHeader for more details.
Trait Implementations§
Source§impl<'a> Clone for ZipSliceEntry<'a>
impl<'a> Clone for ZipSliceEntry<'a>
Source§fn clone(&self) -> ZipSliceEntry<'a>
fn clone(&self) -> ZipSliceEntry<'a>
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more