[][src]Struct cfg::sequence::Sequence

pub struct Sequence<H> {
    pub lhs: Symbol,
    pub rhs: Symbol,
    pub start: u32,
    pub end: Option<u32>,
    pub separator: Separator,
    pub history: H,
}

Sequence rule representation.

Fields

lhs: Symbol

The rule's left-hand side.

rhs: Symbol

The rule's right-hand side.

start: u32

The minimum number of repetitions.

end: Option<u32>

Either the inclusive maximum number of repetitions, or None if the number of repetitions is unlimited.

separator: Separator

The way elements are separated in a sequence, or Null.

history: H

The history carried with the sequence rule.

Methods

impl<H> Sequence<H>[src]

pub fn inclusive(self, start: u32, end: Option<u32>) -> Self[src]

Assigns the inclusive range of the number of repetitions.

pub fn separator(self, sep: Separator) -> Self[src]

Assigns the separator symbol and mode of separation.

Trait Implementations

impl<H: Clone> Clone for Sequence<H>[src]

impl<H: Eq> Eq for Sequence<H>[src]

impl<H: PartialEq> PartialEq<Sequence<H>> for Sequence<H>[src]

impl<H: Debug> Debug for Sequence<H>[src]

impl<H: Hash> Hash for Sequence<H>[src]

impl<H> StructuralPartialEq for Sequence<H>[src]

impl<H> StructuralEq for Sequence<H>[src]

Auto Trait Implementations

impl<H> Send for Sequence<H> where
    H: Send

impl<H> Sync for Sequence<H> where
    H: Sync

impl<H> Unpin for Sequence<H> where
    H: Unpin

impl<H> UnwindSafe for Sequence<H> where
    H: UnwindSafe

impl<H> RefUnwindSafe for Sequence<H> where
    H: RefUnwindSafe

Blanket Implementations

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

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> 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> Borrow<T> for T where
    T: ?Sized
[src]

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

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