pub struct MatchScore(pub u32);Expand description
Score the matcher assigned. Higher is better; 0 means
“doesn’t match” (and the candidate is filtered out before it
becomes a ScoredCandidate).
Tuple Fields§
§0: u32Implementations§
Source§impl MatchScore
impl MatchScore
pub const PERFECT: MatchScore
pub const PREFIX: MatchScore
pub const FUZZY_HIGH: MatchScore
pub const SUBSTRING: MatchScore
pub const FUZZY_LOW: MatchScore
pub fn get(self) -> u32
Trait Implementations§
Source§impl Clone for MatchScore
impl Clone for MatchScore
Source§fn clone(&self) -> MatchScore
fn clone(&self) -> MatchScore
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 MatchScore
Source§impl Debug for MatchScore
impl Debug for MatchScore
Source§impl<'de> Deserialize<'de> for MatchScore
impl<'de> Deserialize<'de> for MatchScore
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl Eq for MatchScore
Source§impl Ord for MatchScore
impl Ord for MatchScore
Source§fn cmp(&self, other: &MatchScore) -> Ordering
fn cmp(&self, other: &MatchScore) -> 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 MatchScore
impl PartialEq for MatchScore
Source§impl PartialOrd for MatchScore
impl PartialOrd for MatchScore
Source§impl Serialize for MatchScore
impl Serialize for MatchScore
impl StructuralPartialEq for MatchScore
Auto Trait Implementations§
impl Freeze for MatchScore
impl RefUnwindSafe for MatchScore
impl Send for MatchScore
impl Sync for MatchScore
impl Unpin for MatchScore
impl UnsafeUnpin for MatchScore
impl UnwindSafe for MatchScore
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,
§impl<Q, K> Comparable<K> for Q
impl<Q, K> Comparable<K> for Q
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.