pub enum ReadPolicy {
Strict,
Lenient,
}Expand description
The conformance-strictness policy a read applies: a threshold over Severity.
Robustness — bounds-checking, never panicking on malformed input — is unconditional and not governed by this. The policy decides only where the fatal line sits on the severity scale.
Variants§
Strict
Fatal at Severity::Conformance and above: the read fails on anything a
conformant filesystem of that family would not carry, so what a strict read returns
is a filesystem whose every field it recognized.
Lenient
Fatal at nothing: a lenient read collects every finding as structured data and rejects no image, so a malformed image is reported rather than refused. This is the reading a whole-image scan reports under.
Implementations§
Trait Implementations§
Source§impl Clone for ReadPolicy
impl Clone for ReadPolicy
Source§fn clone(&self) -> ReadPolicy
fn clone(&self) -> ReadPolicy
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 moreSource§impl Debug for ReadPolicy
impl Debug for ReadPolicy
Source§impl Default for ReadPolicy
impl Default for ReadPolicy
Source§fn default() -> ReadPolicy
fn default() -> ReadPolicy
Returns the “default value” for a type. Read more
Source§impl PartialEq for ReadPolicy
impl PartialEq for ReadPolicy
Source§fn eq(&self, other: &ReadPolicy) -> bool
fn eq(&self, other: &ReadPolicy) -> bool
Tests for
self and other values to be equal, and is used by ==.impl Copy for ReadPolicy
impl Eq for ReadPolicy
impl StructuralPartialEq for ReadPolicy
Auto Trait Implementations§
impl Freeze for ReadPolicy
impl RefUnwindSafe for ReadPolicy
impl Send for ReadPolicy
impl Sync for ReadPolicy
impl Unpin for ReadPolicy
impl UnsafeUnpin for ReadPolicy
impl UnwindSafe for ReadPolicy
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