#[non_exhaustive]pub enum ExtraFieldPolicy {
Zip64Only,
AllowListed(ExtraHeaderIdSet),
AllowKnown,
Permissive,
}Expand description
Which extra fields a reader accepts in local and central member headers.
All policies accept required ZIP64 values. Redundant local sizes require a separate opt-in. Known fields must pass the same layout and agreement checks under every policy. Timestamps and Windows NT security descriptor sizes need not agree between headers.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Zip64Only
Accept only ZIP64 extra fields.
AllowListed(ExtraHeaderIdSet)
Accept only the optional fields in the set. An empty set is equivalent
to Self::Zip64Only.
AllowKnown
Accept all fields in ExtraHeaderId.
Permissive
Accept known fields and skip unknown fields without interpreting or comparing their contents. Truncation and duplicate identifiers are errors.
Other ZIP readers may interpret the skipped fields and report different metadata for the same member.
Trait Implementations§
Source§impl Clone for ExtraFieldPolicy
impl Clone for ExtraFieldPolicy
Source§fn clone(&self) -> ExtraFieldPolicy
fn clone(&self) -> ExtraFieldPolicy
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 moreimpl Copy for ExtraFieldPolicy
Source§impl Debug for ExtraFieldPolicy
impl Debug for ExtraFieldPolicy
Source§impl Default for ExtraFieldPolicy
impl Default for ExtraFieldPolicy
Source§fn default() -> ExtraFieldPolicy
fn default() -> ExtraFieldPolicy
Returns the “default value” for a type. Read more
impl Eq for ExtraFieldPolicy
Source§impl PartialEq for ExtraFieldPolicy
impl PartialEq for ExtraFieldPolicy
impl StructuralPartialEq for ExtraFieldPolicy
Auto Trait Implementations§
impl Forget for ExtraFieldPolicy
impl Freeze for ExtraFieldPolicy
impl Move for ExtraFieldPolicy
impl RefUnwindSafe for ExtraFieldPolicy
impl Send for ExtraFieldPolicy
impl Sync for ExtraFieldPolicy
impl Unpin for ExtraFieldPolicy
impl UnsafeUnpin for ExtraFieldPolicy
impl UnwindSafe for ExtraFieldPolicy
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