Struct futures::stream::Flatten[][src]

#[must_use = "streams do nothing unless polled"]
pub struct Flatten<St> where
    St: Stream
{ /* fields omitted */ }

A combinator used to flatten a stream-of-streams into one long stream of elements.

This combinator is created by the Stream::flatten method.

Methods

impl<St> Flatten<St> where
    St: Stream + Stream,
    <St as Stream>::Item: Stream
[src]

Important traits for &'a mut I

Acquires a reference to the underlying stream that this combinator is pulling from.

Important traits for &'a mut I

Acquires a mutable reference to the underlying stream that this combinator is pulling from.

Note that care must be taken to avoid tampering with the state of the stream which may otherwise confuse this combinator.

Consumes this combinator, returning the underlying stream.

Note that this may discard intermediate state of this combinator, so care should be taken to avoid losing resources when this is called.

Trait Implementations

impl<St> Unpin for Flatten<St> where
    St: Stream + Stream + Unpin,
    <St as Stream>::Item: Stream,
    <St as Stream>::Item: Unpin
[src]

impl<St> Debug for Flatten<St> where
    St: Debug + Stream,
    <St as Stream>::Item: Debug
[src]

Formats the value using the given formatter. Read more

impl<St> Stream for Flatten<St> where
    St: Stream,
    <St as Stream>::Item: Stream
[src]

Values yielded by the stream.

Attempt to pull out the next value of this stream, registering the current task for wakeup if the value is not yet available, and returning None if the stream is exhausted. Read more

Auto Trait Implementations

impl<St> Send for Flatten<St> where
    St: Send,
    <St as Stream>::Item: Send

impl<St> Sync for Flatten<St> where
    St: Sync,
    <St as Stream>::Item: Sync