pub struct PrefixMatcher;Expand description
match:prefix. Default v1 matcher.
Trait Implementations§
Source§impl CandidateMatcher for PrefixMatcher
impl CandidateMatcher for PrefixMatcher
Source§fn matches(
&self,
query: &str,
candidate: &RawCandidate,
) -> Option<(MatchScore, Vec<Range<usize>>)>
fn matches( &self, query: &str, candidate: &RawCandidate, ) -> Option<(MatchScore, Vec<Range<usize>>)>
Score the candidate against
query. None means “no match”
(filter out). The byte ranges record which parts of
candidate.text the matcher consumed – the renderer paints
these with the match-face style.Auto Trait Implementations§
impl Freeze for PrefixMatcher
impl RefUnwindSafe for PrefixMatcher
impl Send for PrefixMatcher
impl Sync for PrefixMatcher
impl Unpin for PrefixMatcher
impl UnsafeUnpin for PrefixMatcher
impl UnwindSafe for PrefixMatcher
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