pub struct Archive { /* private fields */ }
Expand description
An Archive contains general information about a zip files, along with a list of entries.
It is obtained through a state machine like ArchiveFsm, although end-users tend to use higher-levelr interfaces like rc-zip-sync or rc-zip-tokio.
Implementations§
source§impl Archive
impl Archive
sourcepub fn entries(&self) -> impl Iterator<Item = &Entry>
pub fn entries(&self) -> impl Iterator<Item = &Entry>
Iterate over all files in this zip, read from the central directory.
sourcepub fn by_name<N: AsRef<str>>(&self, name: N) -> Option<&Entry>
pub fn by_name<N: AsRef<str>>(&self, name: N) -> Option<&Entry>
Attempts to look up an entry by name. This is usually a bad idea, as names aren’t necessarily normalized in zip archives.
Auto Trait Implementations§
impl Freeze for Archive
impl RefUnwindSafe for Archive
impl Send for Archive
impl Sync for Archive
impl Unpin for Archive
impl UnwindSafe for Archive
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