[][src]Struct futures::stream::Fold

#[must_use = "streams do nothing unless polled"]
pub struct Fold<S, F, Fut, T> where
    Fut: IntoFuture
{ /* fields omitted */ }

A future used to collect all the results of a stream into one generic type.

This future is returned by the Stream::fold method.

Trait Implementations

impl<S, F, Fut, T> Future for Fold<S, F, Fut, T> where
    S: Stream,
    F: FnMut(T, S::Item) -> Fut,
    Fut: IntoFuture<Item = T>,
    S::Error: From<Fut::Error>, 
[src]

type Item = T

The type of value that this future will resolved with if it is successful. Read more

type Error = S::Error

The type of error that this future will resolve with if it fails in a normal fashion. Read more

impl<S: Debug, F: Debug, Fut: Debug, T: Debug> Debug for Fold<S, F, Fut, T> where
    Fut: IntoFuture,
    Fut::Future: Debug
[src]

Auto Trait Implementations

impl<S, F, Fut, T> Unpin for Fold<S, F, Fut, T> where
    F: Unpin,
    S: Unpin,
    T: Unpin,
    <Fut as IntoFuture>::Future: Unpin

impl<S, F, Fut, T> Send for Fold<S, F, Fut, T> where
    F: Send,
    S: Send,
    T: Send,
    <Fut as IntoFuture>::Future: Send

impl<S, F, Fut, T> Sync for Fold<S, F, Fut, T> where
    F: Sync,
    S: Sync,
    T: Sync,
    <Fut as IntoFuture>::Future: Sync

impl<S, F, Fut, T> UnwindSafe for Fold<S, F, Fut, T> where
    F: UnwindSafe,
    S: UnwindSafe,
    T: UnwindSafe,
    <Fut as IntoFuture>::Future: UnwindSafe

impl<S, F, Fut, T> RefUnwindSafe for Fold<S, F, Fut, T> where
    F: RefUnwindSafe,
    S: RefUnwindSafe,
    T: RefUnwindSafe,
    <Fut as IntoFuture>::Future: RefUnwindSafe

Blanket Implementations

impl<F> IntoFuture for F where
    F: Future
[src]

type Future = F

The future that this type can be converted into.

type Item = <F as Future>::Item

The item that the future may resolve with.

type Error = <F as Future>::Error

The error that the future may resolve with.

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

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

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]