[][src]Struct combine::stream::IteratorStream

pub struct IteratorStream<Input>(_);

Wrapper around iterators which allows them to be treated as a stream. Returned by from_iter.

Implementations

impl<Input> IteratorStream<Input> where
    Input: Iterator
[src]

pub fn new<T>(iter: T) -> IteratorStream<Input>

Notable traits for IteratorStream<Input>

impl<Input> Iterator for IteratorStream<Input> where
    Input: Iterator
type Item = Input::Item;
where
    T: IntoIterator<IntoIter = Input, Item = Input::Item>, 
[src]

Converts an Iterator into a stream.

NOTE: This type do not implement Positioned and Clone and must be wrapped with types such as BufferedStreamRef and State to become a Stream which can be parsed

Trait Implementations

impl<Input: Clone> Clone for IteratorStream<Input>[src]

impl<Input: Copy> Copy for IteratorStream<Input>[src]

impl<Input: Debug> Debug for IteratorStream<Input>[src]

impl<T> DefaultPositioned for IteratorStream<T>[src]

impl<Input> Iterator for IteratorStream<Input> where
    Input: Iterator
[src]

type Item = Input::Item

The type of the elements being iterated over.

impl<T: Clone> ResetStream for IteratorStream<T> where
    Self: StreamOnce
[src]

type Checkpoint = Self

impl<Input: Iterator> StreamOnce for IteratorStream<Input> where
    Input::Item: Clone + PartialEq
[src]

type Token = Input::Item

The type of items which is yielded from this stream.

type Range = Input::Item

The type of a range of items yielded from this stream. Types which do not a have a way of yielding ranges of items should just use the Self::Token for this type. Read more

type Position = ()

Type which represents the position in a stream. Ord is required to allow parsers to determine which of two positions are further ahead. Read more

type Error = UnexpectedParse

Auto Trait Implementations

impl<Input> RefUnwindSafe for IteratorStream<Input> where
    Input: RefUnwindSafe

impl<Input> Send for IteratorStream<Input> where
    Input: Send

impl<Input> Sync for IteratorStream<Input> where
    Input: Sync

impl<Input> Unpin for IteratorStream<Input> where
    Input: Unpin

impl<Input> UnwindSafe for IteratorStream<Input> where
    Input: UnwindSafe

Blanket Implementations

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

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

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

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

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

impl<I> IntoIterator for I where
    I: Iterator
[src]

type Item = <I as Iterator>::Item

The type of the elements being iterated over.

type IntoIter = I

Which kind of iterator are we turning this into?

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.