pub struct Part {
pub name: String,
pub data: Vec<u8>,
pub stored: bool,
pub directory: bool,
}Expand description
One entry of a package.
Fields§
§name: StringThe entry’s path inside the package, such as content.xml or
Pictures/100002010000...png.
data: Vec<u8>The entry’s bytes, decompressed.
stored: boolWhether the entry was stored rather than deflated.
Kept so that writing a package it read does not recompress a picture that was already compressed when it went in, which costs time and grows the file.
directory: boolWhether the entry is a directory rather than a file.
An office application writes a few of these — Configurations2/ and
Thumbnails/ among them — and a package that comes back without them is
a package that has been changed. They carry no bytes.
Auto Trait Implementations§
impl Freeze for Part
impl RefUnwindSafe for Part
impl Send for Part
impl Sync for Part
impl Unpin for Part
impl UnsafeUnpin for Part
impl UnwindSafe for Part
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