Struct regex_literal::delimited::ReSequence

source ·
pub struct ReSequence(/* private fields */);
Expand description

ReSequence is the sequence of regex_automata::Regex (can be either single-pattern or multiple-pattern) that can be utilized in a timeline /series of matching events.

Implementations§

source§

impl ReSequence

source

pub const fn new() -> Self

Construct a new, empty ReSequence The Regex vector as resequence’s field 0 will not be allocated in initialization

source

pub fn push(&mut self, elem: Regex)

Appends an element to the back of a collection.

source

pub fn len(&self) -> usize

return the number of elements in ReSequence struct.

source

pub fn iter(&self) -> Iter<'_, Regex>

Returns an iterator over the slice.

The iterator yields all items from start to end

source

pub fn iter_mut(&mut self) -> IterMut<'_, Regex>

Returns an iterator that allows modifying each value.

The iterator yields all items from start to end.

source

pub fn pop(&mut self) -> Option<Regex>

Removes the last element from a vector and returns it, or None if it is empty.

source

pub fn as_slice(&self) -> &[Regex]

Resequence is used as slice.

Trait Implementations§

source§

impl Clone for ReSequence

source§

fn clone(&self) -> ReSequence

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for ReSequence

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl FromIterator<Regex> for ReSequence

Create a value from an iterator.

source§

fn from_iter<I: IntoIterator<Item = Regex>>(iter: I) -> Self

Creates a value from an iterator. Read more
source§

impl IntoIterator for ReSequence

The method that converts ReSequence into an Iterator, which works with for syntax.

§

type Item = Regex

The type of the elements being iterated over.
§

type IntoIter = IntoIter<<ReSequence as IntoIterator>::Item>

Which kind of iterator are we turning this into?
source§

fn into_iter(self) -> Self::IntoIter

Creates an iterator from a value. Read more

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T, U> Into<U> for T
where U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<T> ToOwned for T
where T: Clone,

§

type Owned = T

The resulting type after obtaining ownership.
source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

§

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

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.