pub enum Confidence {
Low,
Medium,
High,
}Expand description
How strongly the evidence supports a reading. Ordered Low < Medium < High
so candidates sort best-first by descending confidence.
Confidence::High— a strong, near-unique MAGIC signature or a full successful structural parse (bplist00,1f 8b, a valid RFC 1950 header, a parseable JSON object, a canonical hyphenated UUID string).Confidence::Medium— a magic matched but the payload failed to fully decode, or a heuristic wrapper (base64/hex) whose decoded payload was itself recognised as a concrete type.Confidence::Low— a purely structural heuristic that a random blob could satisfy by coincidence (16 arbitrary bytes as a UUID; base64/hex text decoding only to more opaque bytes; plain printable text).
Variants§
Low
A coincidence-prone structural heuristic.
Medium
A magic matched but payload decode was partial, or a heuristic wrapper whose payload was recognised.
High
A strong magic signature or a full successful parse.
Trait Implementations§
Source§impl Clone for Confidence
impl Clone for Confidence
Source§fn clone(&self) -> Confidence
fn clone(&self) -> Confidence
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 Confidence
Source§impl Debug for Confidence
impl Debug for Confidence
impl Eq for Confidence
Source§impl Ord for Confidence
impl Ord for Confidence
Source§fn cmp(&self, other: &Confidence) -> Ordering
fn cmp(&self, other: &Confidence) -> Ordering
1.21.0 (const: unstable) · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
Source§impl PartialEq for Confidence
impl PartialEq for Confidence
Source§impl PartialOrd for Confidence
impl PartialOrd for Confidence
Source§impl Serialize for Confidence
impl Serialize for Confidence
impl StructuralPartialEq for Confidence
Auto Trait Implementations§
impl Freeze for Confidence
impl RefUnwindSafe for Confidence
impl Send for Confidence
impl Sync for Confidence
impl Unpin for Confidence
impl UnsafeUnpin for Confidence
impl UnwindSafe for Confidence
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Comparable<K> for Q
impl<Q, K> Comparable<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.