[][src]Struct rec::Rec

pub struct Rec(_);

Constructs a regular expression.

This implements the Builder pattern for Regex.

Methods

impl Rec[src]

pub fn build(self) -> Regex[src]

Builds a Regex from self.

This is only safe to use with Recs that are known prior to runtime. Otherwise use [try_build].

Panics

Panics if self contains an invalid expression.

Trait Implementations

impl Element for Rec[src]

fn group(self) -> Rec where
    Self: Sized
[src]

Converts self into a Rec that is grouped.

impl Default for Rec[src]

impl Clone for Rec[src]

fn clone_from(&mut self, source: &Self)1.0.0[src]

Performs copy-assignment from source. Read more

impl PartialEq<Rec> for Rec[src]

impl Eq for Rec[src]

impl Hash for Rec[src]

fn hash_slice<H>(data: &[Self], state: &mut H) where
    H: Hasher
1.3.0[src]

Feeds a slice of this type into the given [Hasher]. Read more

impl Display for Rec[src]

impl Debug for Rec[src]

impl<'_> Add<Rec> for &'_ str[src]

type Output = Rec

The resulting type after applying the + operator.

fn add(self, rhs: Rec) -> Self::Output[src]

use rec::Element;

let a_rec = "abc" + "xyz".into_rec();

assert_eq!(a_rec, String::from("abcxyz").into_rec());

impl Add<Rec> for String[src]

type Output = Rec

The resulting type after applying the + operator.

fn add(self, rhs: Rec) -> Self::Output[src]

use rec::Element;

let a_rec = String::from("abc") + "xyz".into_rec();

assert_eq!(a_rec, String::from("abcxyz").into_rec());

impl<Rhs: Element> Add<Rhs> for Rec[src]

type Output = Self

The resulting type after applying the + operator.

impl<'_> BitOr<Rec> for &'_ str[src]

type Output = Rec

The resulting type after applying the | operator.

fn bitor(self, rhs: Rec) -> Self::Output[src]

use rec::Element;

let a_rec = "abc" | "xyz".into_rec();

assert_eq!(a_rec, String::from("abc|xyz").into_rec());

impl BitOr<Rec> for String[src]

type Output = Rec

The resulting type after applying the | operator.

fn bitor(self, rhs: Rec) -> Self::Output[src]

use rec::Element;

let a_rec = String::from("abc") | "xyz".into_rec();

assert_eq!(a_rec, String::from("abc|xyz").into_rec());

impl<T: Element> BitOr<T> for Rec[src]

type Output = Self

The resulting type after applying the | operator.

Auto Trait Implementations

impl Send for Rec

impl Sync for Rec

Blanket Implementations

impl<T> From<T> for T[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToString for T where
    T: Display + ?Sized
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> Any for T where
    T: 'static + ?Sized
[src]