Struct futures_util::stream::StreamFuture [−][src]
pub struct StreamFuture<St> { /* fields omitted */ }
Expand description
Future for the into_future
method.
Implementations
Acquires a reference to the underlying stream that this combinator is pulling from.
This method returns an Option
to account for the fact that StreamFuture
’s
implementation of Future::poll
consumes the underlying stream during polling
in order to return it to the caller of Future::poll
if the stream yielded
an element.
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.
This method returns an Option
to account for the fact that StreamFuture
’s
implementation of Future::poll
consumes the underlying stream during polling
in order to return it to the caller of Future::poll
if the stream yielded
an element.
Acquires a pinned 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.
This method returns an Option
to account for the fact that StreamFuture
’s
implementation of Future::poll
consumes the underlying stream during polling
in order to return it to the caller of Future::poll
if the stream yielded
an element.
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.
This method returns an Option
to account for the fact that StreamFuture
’s
implementation of Future::poll
consumes the underlying stream during polling
in order to return it to the caller of Future::poll
if the stream yielded
an element.
Trait Implementations
Returns true
if the underlying future should no longer be polled.
Auto Trait Implementations
impl<St> RefUnwindSafe for StreamFuture<St> where
St: RefUnwindSafe,
impl<St> Send for StreamFuture<St> where
St: Send,
impl<St> Sync for StreamFuture<St> where
St: Sync,
impl<St> Unpin for StreamFuture<St> where
St: Unpin,
impl<St> UnwindSafe for StreamFuture<St> where
St: UnwindSafe,
Blanket Implementations
Mutably borrows from an owned value. Read more
into_future
)The output that the future will produce on completion.
type Future = F
type Future = F
into_future
)Which kind of future are we turning this into?
into_future
)Creates a future from a value.