Struct aho_corasick::nfa::noncontiguous::Builder
source · [−]pub struct Builder { /* private fields */ }
Expand description
A builder for configuring an Aho-Corasick noncontiguous NFA.
This builder has a subset of the options available to a
AhoCorasickBuilder
. Of the shared options,
their behavior is identical.
Implementations
sourceimpl Builder
impl Builder
sourcepub fn new() -> Builder
pub fn new() -> Builder
Create a new builder for configuring an Aho-Corasick noncontiguous NFA.
sourcepub fn build<I, P>(&self, patterns: I) -> Result<NFA, BuildError>where
I: IntoIterator<Item = P>,
P: AsRef<[u8]>,
pub fn build<I, P>(&self, patterns: I) -> Result<NFA, BuildError>where
I: IntoIterator<Item = P>,
P: AsRef<[u8]>,
Build an Aho-Corasick noncontiguous NFA from the given iterator of patterns.
A builder may be reused to create more NFAs.
sourcepub fn match_kind(&mut self, kind: MatchKind) -> &mut Builder
pub fn match_kind(&mut self, kind: MatchKind) -> &mut Builder
Set the desired match semantics.
See
AhoCorasickBuilder::match_kind
for more documentation and examples.
sourcepub fn ascii_case_insensitive(&mut self, yes: bool) -> &mut Builder
pub fn ascii_case_insensitive(&mut self, yes: bool) -> &mut Builder
Enable ASCII-aware case insensitive matching.
See
AhoCorasickBuilder::ascii_case_insensitive
for more documentation and examples.
sourcepub fn prefilter(&mut self, yes: bool) -> &mut Builder
pub fn prefilter(&mut self, yes: bool) -> &mut Builder
Enable heuristic prefilter optimizations.
See
AhoCorasickBuilder::prefilter
for more documentation and examples.
Trait Implementations
Auto Trait Implementations
impl RefUnwindSafe for Builder
impl Send for Builder
impl Sync for Builder
impl Unpin for Builder
impl UnwindSafe for Builder
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more