[][src]Trait moore_common::grind::Grinder

pub trait Grinder {
    type Item: Chisel;
    type Error;
    pub fn next(&mut self) -> Self::Item;
pub fn emit(&mut self, err: Self::Error); pub fn vent<F, E>(self, f: F) -> Vent<Self, F, E>
    where
        Self: Sized,
        F: Fn(E)
, { ... }
pub fn unwrap(self) -> Unwrap<Self>
    where
        Self: Sized
, { ... }
pub fn map_err<F, E>(self, f: F) -> MapErrGrinder<Self, F, E>
    where
        Self: Sized,
        F: Fn(E) -> Self::Error
, { ... }
pub fn peekable(self) -> Peekable<Self>
    where
        Self: Sized
, { ... }
pub fn lookaheadable(self) -> Lookahead<Self>
    where
        Self: Sized
, { ... }
pub fn filter<F>(self, f: F) -> Filter<Self, F>
    where
        Self: Sized,
        F: Fn(&<Self::Item as Chisel>::Value) -> bool
, { ... } }

Associated Types

Loading content...

Required methods

pub fn next(&mut self) -> Self::Item[src]

pub fn emit(&mut self, err: Self::Error)[src]

Loading content...

Provided methods

pub fn vent<F, E>(self, f: F) -> Vent<Self, F, E> where
    Self: Sized,
    F: Fn(E), 
[src]

pub fn unwrap(self) -> Unwrap<Self> where
    Self: Sized
[src]

pub fn map_err<F, E>(self, f: F) -> MapErrGrinder<Self, F, E> where
    Self: Sized,
    F: Fn(E) -> Self::Error
[src]

pub fn peekable(self) -> Peekable<Self> where
    Self: Sized
[src]

pub fn lookaheadable(self) -> Lookahead<Self> where
    Self: Sized
[src]

pub fn filter<F>(self, f: F) -> Filter<Self, F> where
    Self: Sized,
    F: Fn(&<Self::Item as Chisel>::Value) -> bool
[src]

Loading content...

Trait Implementations

impl<I, C: Chisel<Value = I>, E> Iterator for dyn Grinder<Item = C, Error = E>[src]

type Item = I

The type of the elements being iterated over.

Implementors

impl<I, E, C, T> Grinder for Unwrap<T> where
    C: Chisel<Value = Result<I, E>>,
    T: Grinder<Item = C, Error = E>, 
[src]

type Item = Option<I>

type Error = T::Error

impl<I: Iterator> Grinder for Iter<I>[src]

type Item = Option<I::Item>

type Error = ()

impl<R: Read> Grinder for Read<R>[src]

type Item = Option<Result<u8>>

type Error = ()

impl<T> Grinder for Lookahead<T> where
    T: Grinder
[src]

type Item = T::Item

type Error = T::Error

impl<T> Grinder for Peekable<T> where
    T: Grinder
[src]

type Item = T::Item

type Error = T::Error

impl<T> Grinder for Utf8<T> where
    T: Grinder<Item = Option<u8>>, 
[src]

type Item = Option<(usize, char, u8)>

type Error = T::Error

impl<T, E, F> Grinder for MapErrGrinder<T, F, E> where
    T: Grinder,
    F: Fn(E) -> T::Error
[src]

type Item = T::Item

type Error = E

impl<T, F> Grinder for Filter<T, F> where
    T: Grinder,
    F: Fn(&<T::Item as Chisel>::Value) -> bool
[src]

type Item = T::Item

type Error = T::Error

impl<T: Grinder, E, F> Grinder for Vent<T, F, E> where
    F: Fn(E), 
[src]

type Item = T::Item

type Error = E

Loading content...