#[non_exhaustive]pub enum Verdict {
Conformant,
NonConformant(Malformed),
Undetermined(Unsupported),
OutOfScope(String),
}Expand description
What can be said about a container after reading it.
Four answers rather than two. SPEC 2.2 and SPEC 3 require that a container whose metadata member cannot be read is reported as neither conformant nor non-conformant, and SPEC 2.4 puts a container declaring another version outside this document’s conformance question rather than failing it. A yes-or-no return could say neither thing.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Conformant
Conformant to the version this build implements.
NonConformant(Malformed)
Not conformant, and this is the rule it breaks.
Undetermined(Unsupported)
The metadata member could not be read, so conformance cannot be established from the file (SPEC 2.2). Not a failure, and not a pass.
OutOfScope(String)
Declares a slipcase_version this build does not implement (SPEC 2.4).
Outside the question rather than failing it.
Implementations§
Source§impl Verdict
impl Verdict
Sourcepub fn is_conformant(&self) -> bool
pub fn is_conformant(&self) -> bool
Whether this is Verdict::Conformant.
Deliberately not is_ok: the other three are not failures in the same
sense, and two of them are not failures at all.