pub struct BoundsBuilder<'a> { /* private fields */ }
Expand description
Build a set of string matching rules
Implementations§
Source§impl<'a> BoundsBuilder<'a>
impl<'a> BoundsBuilder<'a>
pub fn new() -> Self
Sourcepub fn as_vec(&self) -> Vec<StringBounds<'a>>
pub fn as_vec(&self) -> Vec<StringBounds<'a>>
Return a vector of StringBounds enum rules for use with filter_all_conditional()
Sourcepub fn starts_with_ci(&mut self, pattern: &'a str, is_positive: bool) -> Self
pub fn starts_with_ci(&mut self, pattern: &'a str, is_positive: bool) -> Self
Add a “starts_with” rule with a positive flags in case-insensitive mode
Sourcepub fn starts_with_ci_alphanum(
&mut self,
pattern: &'a str,
is_positive: bool,
) -> Self
pub fn starts_with_ci_alphanum( &mut self, pattern: &'a str, is_positive: bool, ) -> Self
Add a “starts_with” rule with a positive flags in case-insensitive mode evaluating only alphanumeric characters
Sourcepub fn starts_with_cs(&mut self, pattern: &'a str, is_positive: bool) -> Self
pub fn starts_with_cs(&mut self, pattern: &'a str, is_positive: bool) -> Self
Add a “starts_with” rule with a positive flag in case-sensitive mode
Sourcepub fn starting_with(
&mut self,
pattern: &'a str,
case_insensitive: bool,
) -> Self
pub fn starting_with( &mut self, pattern: &'a str, case_insensitive: bool, ) -> Self
Add a positive “starts_with” rule with a case-insensitive flag
Sourcepub fn starting_with_ci(&mut self, pattern: &'a str) -> Self
pub fn starting_with_ci(&mut self, pattern: &'a str) -> Self
Add a positive “starts_with” rule in case-insensitive mode
Sourcepub fn starting_with_ci_alphanum(&mut self, pattern: &'a str) -> Self
pub fn starting_with_ci_alphanum(&mut self, pattern: &'a str) -> Self
Add a positive “starts_with” rule in case-insensitive mode evaluating only alphanumeric characters
Sourcepub fn starting_with_cs(&mut self, pattern: &'a str) -> Self
pub fn starting_with_cs(&mut self, pattern: &'a str) -> Self
Add a positive “starts_with” rule in case-sensitive mode
Sourcepub fn not_starting_with(
&mut self,
pattern: &'a str,
case_insensitive: bool,
) -> Self
pub fn not_starting_with( &mut self, pattern: &'a str, case_insensitive: bool, ) -> Self
Add a negative “starts_with” rule with a case-insensitive flag
Sourcepub fn not_starting_with_ci(&mut self, pattern: &'a str) -> Self
pub fn not_starting_with_ci(&mut self, pattern: &'a str) -> Self
Add a negative “starts_with” rule in case-insensitive mode
Sourcepub fn not_starting_with_ci_alphanum(&mut self, pattern: &'a str) -> Self
pub fn not_starting_with_ci_alphanum(&mut self, pattern: &'a str) -> Self
Add a negative “starts_with” rule in case-insensitive mode evaluating only alphanumeric characters
Sourcepub fn not_starting_with_cs(&mut self, pattern: &'a str) -> Self
pub fn not_starting_with_cs(&mut self, pattern: &'a str) -> Self
Add a negative “starts_with” rule in case-sensitive mode
Sourcepub fn contains(
&mut self,
pattern: &'a str,
is_positive: bool,
case_insensitive: bool,
) -> Self
pub fn contains( &mut self, pattern: &'a str, is_positive: bool, case_insensitive: bool, ) -> Self
Add a “contains” rule with a positive flag in case-insensitive mode
Sourcepub fn contains_ci_alphanum(
&mut self,
pattern: &'a str,
is_positive: bool,
) -> Self
pub fn contains_ci_alphanum( &mut self, pattern: &'a str, is_positive: bool, ) -> Self
Add a “contains” rule with a positive flags in case-insensitive mode evaluating only alphanumeric characters
Sourcepub fn contains_ci(&mut self, pattern: &'a str, is_positive: bool) -> Self
pub fn contains_ci(&mut self, pattern: &'a str, is_positive: bool) -> Self
Add a “contains” rule with a positive flags in case-insensitive mode
Sourcepub fn contains_cs(&mut self, pattern: &'a str, is_positive: bool) -> Self
pub fn contains_cs(&mut self, pattern: &'a str, is_positive: bool) -> Self
Add a “contains” rule with a positive flags in case-sensitive mode
Sourcepub fn containing(&mut self, pattern: &'a str, case_insensitive: bool) -> Self
pub fn containing(&mut self, pattern: &'a str, case_insensitive: bool) -> Self
Add a positive “contains” rule with a case-insensitive flag
Sourcepub fn containing_ci(&mut self, pattern: &'a str) -> Self
pub fn containing_ci(&mut self, pattern: &'a str) -> Self
Add a positive “contains” rule in case-insensitive mode
Sourcepub fn containing_ci_alphanum(&mut self, pattern: &'a str) -> Self
pub fn containing_ci_alphanum(&mut self, pattern: &'a str) -> Self
Add a positive “contains” rule in case-insensitive mode evaluating only alphanumeric characters
Sourcepub fn containing_cs(&mut self, pattern: &'a str) -> Self
pub fn containing_cs(&mut self, pattern: &'a str) -> Self
Add a positive “contains” rule as true in case-sensitive mode
Sourcepub fn not_containing(
&mut self,
pattern: &'a str,
case_insensitive: bool,
) -> Self
pub fn not_containing( &mut self, pattern: &'a str, case_insensitive: bool, ) -> Self
Add a negative “contains” rule with a case-insensitive flag
Sourcepub fn not_containing_ci(&mut self, pattern: &'a str) -> Self
pub fn not_containing_ci(&mut self, pattern: &'a str) -> Self
Add a negative “contains” rule in case-insensitive mode
Sourcepub fn not_containing_ci_alphanum(&mut self, pattern: &'a str) -> Self
pub fn not_containing_ci_alphanum(&mut self, pattern: &'a str) -> Self
Add a negative “contains” rule in case-insensitive mode evaluating only alphanumeric characters
Sourcepub fn not_containing_cs(&mut self, pattern: &'a str) -> Self
pub fn not_containing_cs(&mut self, pattern: &'a str) -> Self
Add a negative “contains” rule in case-sensitive mode
Sourcepub fn ends_with_ci(&mut self, pattern: &'a str, is_positive: bool) -> Self
pub fn ends_with_ci(&mut self, pattern: &'a str, is_positive: bool) -> Self
Add an “ends_with” rule with a positive flag in case-insensitive mode
Sourcepub fn ends_with_ci_alphanum(
&mut self,
pattern: &'a str,
is_positive: bool,
) -> Self
pub fn ends_with_ci_alphanum( &mut self, pattern: &'a str, is_positive: bool, ) -> Self
Add a “ends_with” rule with a positive flags in case-insensitive mode evaluating only alphanumeric characters
Sourcepub fn ends_with_cs(&mut self, pattern: &'a str, is_positive: bool) -> Self
pub fn ends_with_cs(&mut self, pattern: &'a str, is_positive: bool) -> Self
Add an “ends_with” rule with a positive flag in case-sensitive mode
Sourcepub fn ending_with(&mut self, pattern: &'a str, case_insensitive: bool) -> Self
pub fn ending_with(&mut self, pattern: &'a str, case_insensitive: bool) -> Self
Add a positive “ends_with” rule with a case-insensitive flag
Sourcepub fn ending_with_ci(&mut self, pattern: &'a str) -> Self
pub fn ending_with_ci(&mut self, pattern: &'a str) -> Self
Add a positive “ends_with” rule in case-insensitive mode
Sourcepub fn ending_with_ci_alphanum(&mut self, pattern: &'a str) -> Self
pub fn ending_with_ci_alphanum(&mut self, pattern: &'a str) -> Self
Add a positive “ends_with” rule in case-insensitive mode evaluating only alphanumeric characters
Sourcepub fn ending_with_cs(&mut self, pattern: &'a str) -> Self
pub fn ending_with_cs(&mut self, pattern: &'a str) -> Self
Add a positive “ends_with” rule in case-sensitive mode
Sourcepub fn not_ending_with(
&mut self,
pattern: &'a str,
case_insensitive: bool,
) -> Self
pub fn not_ending_with( &mut self, pattern: &'a str, case_insensitive: bool, ) -> Self
Add a negative “ends_with” rule with a case-insensitive flag
Sourcepub fn not_ending_with_ci(&mut self, pattern: &'a str) -> Self
pub fn not_ending_with_ci(&mut self, pattern: &'a str) -> Self
Add a negative “ends_with” rule in case-insensitive mode
Sourcepub fn not_ending_with_ci_alphanum(&mut self, pattern: &'a str) -> Self
pub fn not_ending_with_ci_alphanum(&mut self, pattern: &'a str) -> Self
Add a negative “ends_with” rule in case-insensitive mode evaluating only alphanumeric characters
Sourcepub fn not_ending_with_cs(&mut self, pattern: &'a str) -> Self
pub fn not_ending_with_cs(&mut self, pattern: &'a str) -> Self
Add a negative “ends_with” in case-sensitive mode
Sourcepub fn matches_whole(
&mut self,
pattern: &'a str,
is_positive: bool,
case_insensitive: bool,
) -> Self
pub fn matches_whole( &mut self, pattern: &'a str, is_positive: bool, case_insensitive: bool, ) -> Self
Add an “whole_match” rule with a positive and case-insensitive flags
Sourcepub fn matches_whole_ci(&mut self, pattern: &'a str, is_positive: bool) -> Self
pub fn matches_whole_ci(&mut self, pattern: &'a str, is_positive: bool) -> Self
Add an “whole_match” rule with a positive flag in case-sensitive mode
Sourcepub fn matches_whole_cs(&mut self, pattern: &'a str, is_positive: bool) -> Self
pub fn matches_whole_cs(&mut self, pattern: &'a str, is_positive: bool) -> Self
Add an “whole_match” rule with a positive flag in case-insensitive mode
pub fn is(&mut self, pattern: &'a str, case_insensitive: bool) -> Self
pub fn is_ci(&mut self, pattern: &'a str) -> Self
pub fn is_not(&mut self, pattern: &'a str, case_insensitive: bool) -> Self
pub fn is_not_ci(&mut self, pattern: &'a str) -> Self
pub fn is_not_cs(&mut self, pattern: &'a str) -> Self
pub fn and(&mut self, rules: BoundsBuilder<'a>) -> Self
pub fn or(&mut self, rules: BoundsBuilder<'a>) -> Self
pub fn or_true( &mut self, patterns: &'a [&str], case_mode: CaseMatchMode, position: BoundsPosition, ) -> Self
pub fn or_starts_with( &mut self, patterns: &'a [&str], case_mode: CaseMatchMode, ) -> Self
pub fn or_starting_with_ci(&mut self, patterns: &'a [&str]) -> Self
pub fn or_starting_with_cs(&mut self, patterns: &'a [&str]) -> Self
pub fn or_starting_with_ci_alphanum(&mut self, patterns: &'a [&str]) -> Self
pub fn or_contains( &mut self, patterns: &'a [&str], case_mode: CaseMatchMode, ) -> Self
pub fn or_containing_ci(&mut self, patterns: &'a [&str]) -> Self
pub fn or_containing_cs(&mut self, patterns: &'a [&str]) -> Self
pub fn or_containing_ci_alphanum(&mut self, patterns: &'a [&str]) -> Self
pub fn or_ends_with( &mut self, patterns: &'a [&str], case_mode: CaseMatchMode, ) -> Self
pub fn or_ending_with_ci(&mut self, patterns: &'a [&str]) -> Self
pub fn or_ending_with_cs(&mut self, patterns: &'a [&str]) -> Self
pub fn or_ending_with_ci_alphanum(&mut self, patterns: &'a [&str]) -> Self
pub fn or_is(&mut self, patterns: &'a [&str], case_mode: CaseMatchMode) -> Self
pub fn or_is_ci(&mut self, patterns: &'a [&str]) -> Self
pub fn or_is_cs(&mut self, patterns: &'a [&str]) -> Self
pub fn or_is_ci_alphanum(&mut self, patterns: &'a [&str]) -> Self
pub fn and_true( &mut self, patterns: &'a [&str], case_mode: CaseMatchMode, position: BoundsPosition, ) -> Self
pub fn and_false( &mut self, patterns: &'a [&str], case_mode: CaseMatchMode, position: BoundsPosition, ) -> Self
pub fn and_starts_with( &mut self, patterns: &'a [&str], case_mode: CaseMatchMode, ) -> Self
pub fn and_not_starts_with( &mut self, patterns: &'a [&str], case_mode: CaseMatchMode, ) -> Self
pub fn and_starting_with_ci(&mut self, patterns: &'a [&str]) -> Self
pub fn and_not_starting_with_ci(&mut self, patterns: &'a [&str]) -> Self
pub fn and_starting_with_cs(&mut self, patterns: &'a [&str]) -> Self
pub fn and_not_starting_with_cs(&mut self, patterns: &'a [&str]) -> Self
pub fn and_starting_with_ci_alphanum(&mut self, patterns: &'a [&str]) -> Self
pub fn and_not_starting_with_ci_alphanum( &mut self, patterns: &'a [&str], ) -> Self
pub fn and_contains( &mut self, patterns: &'a [&str], case_mode: CaseMatchMode, ) -> Self
pub fn and_not_contains( &mut self, patterns: &'a [&str], case_mode: CaseMatchMode, ) -> Self
pub fn and_containing_ci(&mut self, patterns: &'a [&str]) -> Self
pub fn and_not_containing_ci(&mut self, patterns: &'a [&str]) -> Self
pub fn and_containing_cs(&mut self, patterns: &'a [&str]) -> Self
pub fn and_not_containing_cs(&mut self, patterns: &'a [&str]) -> Self
pub fn and_containing_ci_alphanum(&mut self, patterns: &'a [&str]) -> Self
pub fn and_not_containing_ci_alphanum(&mut self, patterns: &'a [&str]) -> Self
pub fn and_ends_with( &mut self, patterns: &'a [&str], case_mode: CaseMatchMode, ) -> Self
pub fn and_not_ends_with( &mut self, patterns: &'a [&str], case_mode: CaseMatchMode, ) -> Self
pub fn and_ending_with_ci(&mut self, patterns: &'a [&str]) -> Self
pub fn and_not_ending_with_ci(&mut self, patterns: &'a [&str]) -> Self
pub fn and_ending_with_cs(&mut self, patterns: &'a [&str]) -> Self
pub fn and_not_ending_with_cs(&mut self, patterns: &'a [&str]) -> Self
pub fn and_ending_with_ci_alphanum(&mut self, patterns: &'a [&str]) -> Self
pub fn and_not_ending_with_ci_alphanum(&mut self, patterns: &'a [&str]) -> Self
pub fn and_is(&mut self, patterns: &'a [&str], case_mode: CaseMatchMode) -> Self
pub fn and_is_not( &mut self, patterns: &'a [&str], case_mode: CaseMatchMode, ) -> Self
pub fn and_is_ci(&mut self, patterns: &'a [&str]) -> Self
pub fn and_is_not_ci(&mut self, patterns: &'a [&str]) -> Self
pub fn and_is_cs(&mut self, patterns: &'a [&str]) -> Self
pub fn and_is_not_cs(&mut self, patterns: &'a [&str]) -> Self
pub fn and_is_ci_alphanum(&mut self, patterns: &'a [&str]) -> Self
pub fn and_is_not_ci_alphanum(&mut self, patterns: &'a [&str]) -> Self
Trait Implementations§
Source§impl<'a> Clone for BoundsBuilder<'a>
impl<'a> Clone for BoundsBuilder<'a>
Source§fn clone(&self) -> BoundsBuilder<'a>
fn clone(&self) -> BoundsBuilder<'a>
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read more