Struct Config
struct Config { ... }
The configuration for a packed multiple pattern searcher.
The configuration is currently limited only to being able to select the match semantics (leftmost-first or leftmost-longest) of a searcher. In the future, more knobs may be made available.
A configuration produces a packed::Builder, which in turn can
be used to construct a packed::Searcher for searching.
Example
This example shows how to use leftmost-longest semantics instead of the default (leftmost-first).
use ;
#
# if cfg! else
Implementations
impl Config
fn new() -> ConfigCreate a new default configuration. A default configuration uses leftmost-first match semantics.
fn builder(self: &Self) -> BuilderCreate a packed builder from this configuration. The builder can be used to accumulate patterns and create a
Searcherfrom them.fn match_kind(self: &mut Self, kind: MatchKind) -> &mut ConfigSet the match semantics for this configuration.
fn heuristic_pattern_limits(self: &mut Self, yes: bool) -> &mut ConfigRequest that heuristic limitations on the number of patterns be employed. This useful to disable for benchmarking where one wants to explore how Teddy performs on large number of patterns even if the heuristics would otherwise refuse construction.
This is enabled by default.
impl Clone for Config
fn clone(self: &Self) -> Config
impl Debug for Config
fn fmt(self: &Self, f: &mut Formatter<'_>) -> Result
impl Default for Config
fn default() -> Config
impl Freeze for Config
impl RefUnwindSafe for Config
impl Send for Config
impl Sync for Config
impl Unpin for Config
impl UnsafeUnpin for Config
impl UnwindSafe for Config
impl<T> Any for Config
fn type_id(self: &Self) -> TypeId
impl<T> Borrow for Config
fn borrow(self: &Self) -> &T
impl<T> BorrowMut for Config
fn borrow_mut(self: &mut Self) -> &mut T
impl<T> CloneToUninit for Config
unsafe fn clone_to_uninit(self: &Self, dest: *mut u8)
impl<T> From for Config
fn from(t: T) -> TReturns the argument unchanged.
impl<T> ToOwned for Config
fn to_owned(self: &Self) -> Tfn clone_into(self: &Self, target: &mut T)
impl<T, U> Into for Config
fn into(self: Self) -> UCalls
U::from(self).That is, this conversion is whatever the implementation of
[From]<T> for Uchooses to do.
impl<T, U> TryFrom for Config
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
impl<T, U> TryInto for Config
fn try_into(self: Self) -> Result<U, <U as TryFrom<T>>::Error>