[][src]Trait gobble::chars::CharBool

pub trait CharBool: Sized {
    fn char_bool(&self, c: char) -> bool;

    fn expected(&self) -> Expected { ... }
fn one(self) -> OneChar<Self> { ... }
fn any(self) -> CharStar<Self> { ... }
fn star(self) -> CharStar<Self> { ... }
fn min_n(self, min: usize) -> CharMin<Self> { ... }
fn plus(self) -> CharPlus<Self> { ... }
fn skip_star(self) -> CharSkip<Self> { ... }
fn skip_plus(self) -> CharSkipPlus<Self> { ... }
fn skip_exact(self, n: usize) -> CharSkipExact<Self> { ... }
fn except<E: CharBool>(self, e: E) -> CharsExcept<Self, E> { ... }
fn exact(self, n: usize) -> CharExact<Self> { ... } }

Required methods

fn char_bool(&self, c: char) -> bool

Loading content...

Provided methods

fn expected(&self) -> Expected

fn one(self) -> OneChar<Self>

fn any(self) -> CharStar<Self>

👎 Deprecated since 0.4.0:

Use 'star' instead

fn star(self) -> CharStar<Self>

fn min_n(self, min: usize) -> CharMin<Self>

min_n not min to avoid ambiguity with std::cmp::Ord

fn plus(self) -> CharPlus<Self>

fn skip_star(self) -> CharSkip<Self>

fn skip_plus(self) -> CharSkipPlus<Self>

fn skip_exact(self, n: usize) -> CharSkipExact<Self>

fn except<E: CharBool>(self, e: E) -> CharsExcept<Self, E>

 use gobble::*;
 assert_eq!(
     Any.except("_").min_n(4).parse_s("asedf_wes"),
     Ok("asedf".to_string())
     );

fn exact(self, n: usize) -> CharExact<Self>

Loading content...

Implementations on Foreign Types

impl CharBool for char[src]

impl CharBool for &'static str[src]

impl<A: CharBool, B: CharBool> CharBool for (A, B)[src]

impl<A: CharBool, B: CharBool, C: CharBool> CharBool for (A, B, C)[src]

impl<A, B, C, D> CharBool for (A, B, C, D) where
    A: CharBool,
    B: CharBool,
    C: CharBool,
    D: CharBool
[src]

impl<A, B, C, D, E> CharBool for (A, B, C, D, E) where
    A: CharBool,
    B: CharBool,
    C: CharBool,
    D: CharBool,
    E: CharBool
[src]

impl<A, B, C, D, E, F> CharBool for (A, B, C, D, E, F) where
    A: CharBool,
    B: CharBool,
    C: CharBool,
    D: CharBool,
    E: CharBool,
    F: CharBool
[src]

Loading content...

Implementors

impl CharBool for Alpha[src]

impl CharBool for Any[src]

impl CharBool for HexDigit[src]

impl CharBool for NumDigit[src]

impl CharBool for WS[src]

impl CharBool for WSL[src]

impl<A: CharBool, E: CharBool> CharBool for CharsExcept<A, E>[src]

impl<F: Fn(char) -> bool> CharBool for F[src]

Loading content...