pub struct ZipStreamReader<R>(/* private fields */);Expand description
Stream decoder for zip.
Implementations§
Source§impl<R> ZipStreamReader<R>
impl<R> ZipStreamReader<R>
Source§impl<R: Read> ZipStreamReader<R>
impl<R: Read> ZipStreamReader<R>
Sourcepub fn visit<V: ZipStreamVisitor>(self, visitor: &mut V) -> ZipResult<()>
pub fn visit<V: ZipStreamVisitor>(self, visitor: &mut V) -> ZipResult<()>
Iterate over the stream and extract all file and their metadata.
Sourcepub fn extract<P: AsRef<Path>>(self, directory: P) -> ZipResult<()>
pub fn extract<P: AsRef<Path>>(self, directory: P) -> ZipResult<()>
Extract a Zip archive into a directory, overwriting files if they
already exist. Paths are sanitized with ZipFile::enclosed_name.
Extraction is not atomic; If an error is encountered, some of the files may be left on disk. The file(s) and dir(s) are first created, then the permissions are applied to them
Extraction of symlink is not possible since we don’t have access to the external attributes in the local headers of the entries
Trait Implementations§
Auto Trait Implementations§
impl<R> Freeze for ZipStreamReader<R>where
R: Freeze,
impl<R> RefUnwindSafe for ZipStreamReader<R>where
R: RefUnwindSafe,
impl<R> Send for ZipStreamReader<R>where
R: Send,
impl<R> Sync for ZipStreamReader<R>where
R: Sync,
impl<R> Unpin for ZipStreamReader<R>where
R: Unpin,
impl<R> UnsafeUnpin for ZipStreamReader<R>where
R: UnsafeUnpin,
impl<R> UnwindSafe for ZipStreamReader<R>where
R: UnwindSafe,
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