Enum aho_corasick::packed::api::MatchKind
source · #[non_exhaustive]pub enum MatchKind {
LeftmostFirst,
LeftmostLongest,
}
Expand description
A knob for controlling the match semantics of a packed multiple string searcher.
This differs from the MatchKind
type in the top-level
crate module in that it doesn’t support “standard” match semantics,
and instead only supports leftmost-first or leftmost-longest. Namely,
“standard” semantics cannot be easily supported by packed searchers.
For more information on the distinction between leftmost-first and
leftmost-longest, see the docs on the top-level MatchKind
type.
Unlike the top-level MatchKind
type, the default match semantics for this
type are leftmost-first.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
LeftmostFirst
Use leftmost-first match semantics, which reports leftmost matches. When there are multiple possible leftmost matches, the match corresponding to the pattern that appeared earlier when constructing the automaton is reported.
This is the default.
LeftmostLongest
Use leftmost-longest match semantics, which reports leftmost matches. When there are multiple possible leftmost matches, the longest match is chosen.
Trait Implementations§
impl Copy for MatchKind
impl Eq for MatchKind
impl StructuralPartialEq for MatchKind
Auto Trait Implementations§
impl Freeze for MatchKind
impl RefUnwindSafe for MatchKind
impl Send for MatchKind
impl Sync for MatchKind
impl Unpin for MatchKind
impl UnwindSafe for MatchKind
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
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
clone_to_uninit
)