[][src]Struct source::Source

pub struct Source<A: 'static>(_);

Methods

impl<A: 'static> Source<A>[src]

pub fn next(&mut self) -> Option<A>[src]

pub fn has_next(&mut self) -> bool[src]

pub fn new<F: FnMut() -> Option<A> + 'static>(function: F) -> Source<A>[src]

pub fn empty() -> Source<A>[src]

pub fn single(a: A) -> Source<A>[src]

pub fn map<B, F: FnMut(A) -> B + 'static>(self, function: F) -> Source<B>[src]

pub fn filter<F: FnMut(&A) -> bool + 'static>(self, function: F) -> Source<A>[src]

pub fn fold<Accumulator, F: FnMut(Accumulator, A) -> Accumulator>(
    self,
    initial: Accumulator,
    function: F
) -> Accumulator
[src]

pub fn flat_map<B, Next: FnMut(A) -> Source<B> + 'static>(
    self,
    next: Next
) -> Source<B>
[src]

pub fn concat(self, other: Source<A>) -> Source<A>[src]

pub fn append(self, last: A) -> Source<A>[src]

pub fn prepend(self, head: A) -> Source<A>[src]

pub fn count<F: Fn(A) -> bool>(self, predicate: F) -> i32[src]

impl<A> Source<Source<A>>[src]

pub fn flatten(self) -> Source<A>[src]

impl<A: Clone> Source<A>[src]

pub fn peek(&mut self) -> Option<A>[src]

pub fn replicate(n: u32, element: A) -> Source<A>[src]

impl Source<char>[src]

impl<Snippet: Into<Box<str>>> Source<Snippet>[src]

pub fn join<Separator: Into<Box<str>>>(self, separator: Separator) -> String[src]

impl<A: Debug> Source<A>[src]

pub fn debug(self) -> String[src]

Trait Implementations

impl<A, I: Iterator<Item = A> + 'static> From<I> for Source<A>[src]

impl<A> IntoIterator for Source<A>[src]

type Item = A

The type of the elements being iterated over.

type IntoIter = SourceIterator<A>

Which kind of iterator are we turning this into?

Auto Trait Implementations

impl<A> !Send for Source<A>

impl<A> !Sync for Source<A>

impl<A> Unpin for Source<A>

impl<A> !UnwindSafe for Source<A>

impl<A> !RefUnwindSafe for Source<A>

Blanket Implementations

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

impl<T> From<T> for 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, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = !

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]