[−][src]Struct futures::compat::Compat
Methods
impl<T> Compat<T>
[src]
impl<T> Compat<T>
pub fn into_inner(self) -> T
[src]
pub fn into_inner(self) -> T
Returns the inner item.
Trait Implementations
impl<St> Stream for Compat<St> where
St: TryStream + Unpin,
[src]
impl<St> Stream for Compat<St> where
St: TryStream + Unpin,
type Item = <St as TryStream>::Ok
The type of item this stream will yield on success.
type Error = <St as TryStream>::Error
The type of error this stream may generate.
fn poll(
&mut self
) -> Result<Async<Option<<Compat<St> as Stream>::Item>>, <Compat<St> as Stream>::Error>
[src]
fn poll(
&mut self
) -> Result<Async<Option<<Compat<St> as Stream>::Item>>, <Compat<St> as Stream>::Error>
Attempt to pull out the next value of this stream, returning None
if the stream is finished. Read more
fn wait(self) -> Wait<Self>
[src]
fn wait(self) -> Wait<Self>
Creates an iterator which blocks the current thread until each item of this stream is resolved. Read more
fn into_future(self) -> StreamFuture<Self>
[src]
fn into_future(self) -> StreamFuture<Self>
Converts this stream into a Future
. Read more
fn map<U, F>(self, f: F) -> Map<Self, F> where
F: FnMut(Self::Item) -> U,
[src]
fn map<U, F>(self, f: F) -> Map<Self, F> where
F: FnMut(Self::Item) -> U,
Converts a stream of type T
to a stream of type U
. Read more
fn map_err<U, F>(self, f: F) -> MapErr<Self, F> where
F: FnMut(Self::Error) -> U,
[src]
fn map_err<U, F>(self, f: F) -> MapErr<Self, F> where
F: FnMut(Self::Error) -> U,
Converts a stream of error type T
to a stream of error type U
. Read more
fn filter<F>(self, f: F) -> Filter<Self, F> where
F: FnMut(&Self::Item) -> bool,
[src]
fn filter<F>(self, f: F) -> Filter<Self, F> where
F: FnMut(&Self::Item) -> bool,
Filters the values produced by this stream according to the provided predicate. Read more
fn filter_map<F, B>(self, f: F) -> FilterMap<Self, F> where
F: FnMut(Self::Item) -> Option<B>,
[src]
fn filter_map<F, B>(self, f: F) -> FilterMap<Self, F> where
F: FnMut(Self::Item) -> Option<B>,
Filters the values produced by this stream while simultaneously mapping them to a different type. Read more
fn then<F, U>(self, f: F) -> Then<Self, F, U> where
F: FnMut(Result<Self::Item, Self::Error>) -> U,
U: IntoFuture,
[src]
fn then<F, U>(self, f: F) -> Then<Self, F, U> where
F: FnMut(Result<Self::Item, Self::Error>) -> U,
U: IntoFuture,
Chain on a computation for when a value is ready, passing the resulting item to the provided closure f
. Read more
fn and_then<F, U>(self, f: F) -> AndThen<Self, F, U> where
F: FnMut(Self::Item) -> U,
U: IntoFuture<Error = Self::Error>,
[src]
fn and_then<F, U>(self, f: F) -> AndThen<Self, F, U> where
F: FnMut(Self::Item) -> U,
U: IntoFuture<Error = Self::Error>,
Chain on a computation for when a value is ready, passing the successful results to the provided closure f
. Read more
fn or_else<F, U>(self, f: F) -> OrElse<Self, F, U> where
F: FnMut(Self::Error) -> U,
U: IntoFuture<Item = Self::Item>,
[src]
fn or_else<F, U>(self, f: F) -> OrElse<Self, F, U> where
F: FnMut(Self::Error) -> U,
U: IntoFuture<Item = Self::Item>,
Chain on a computation for when an error happens, passing the erroneous result to the provided closure f
. Read more
fn collect(self) -> Collect<Self>
[src]
fn collect(self) -> Collect<Self>
Collect all of the values of this stream into a vector, returning a future representing the result of that computation. Read more
fn concat2(self) -> Concat2<Self> where
Self::Item: Extend<<Self::Item as IntoIterator>::Item>,
Self::Item: IntoIterator,
Self::Item: Default,
[src]
fn concat2(self) -> Concat2<Self> where
Self::Item: Extend<<Self::Item as IntoIterator>::Item>,
Self::Item: IntoIterator,
Self::Item: Default,
Concatenate all results of a stream into a single extendable destination, returning a future representing the end result. Read more
fn concat(self) -> Concat<Self> where
Self::Item: Extend<<Self::Item as IntoIterator>::Item>,
Self::Item: IntoIterator,
[src]
fn concat(self) -> Concat<Self> where
Self::Item: Extend<<Self::Item as IntoIterator>::Item>,
Self::Item: IntoIterator,
: please use Stream::concat2
instead
Concatenate all results of a stream into a single extendable destination, returning a future representing the end result. Read more
fn fold<F, T, Fut>(self, init: T, f: F) -> Fold<Self, F, Fut, T> where
F: FnMut(T, Self::Item) -> Fut,
Fut: IntoFuture<Item = T>,
Self::Error: From<<Fut as IntoFuture>::Error>,
[src]
fn fold<F, T, Fut>(self, init: T, f: F) -> Fold<Self, F, Fut, T> where
F: FnMut(T, Self::Item) -> Fut,
Fut: IntoFuture<Item = T>,
Self::Error: From<<Fut as IntoFuture>::Error>,
Execute an accumulating computation over a stream, collecting all the values into one final result. Read more
fn flatten(self) -> Flatten<Self> where
Self::Item: Stream,
<Self::Item as Stream>::Error: From<Self::Error>,
[src]
fn flatten(self) -> Flatten<Self> where
Self::Item: Stream,
<Self::Item as Stream>::Error: From<Self::Error>,
Flattens a stream of streams into just one continuous stream. Read more
fn skip_while<P, R>(self, pred: P) -> SkipWhile<Self, P, R> where
P: FnMut(&Self::Item) -> R,
R: IntoFuture<Item = bool, Error = Self::Error>,
[src]
fn skip_while<P, R>(self, pred: P) -> SkipWhile<Self, P, R> where
P: FnMut(&Self::Item) -> R,
R: IntoFuture<Item = bool, Error = Self::Error>,
Skip elements on this stream while the predicate provided resolves to true
. Read more
fn take_while<P, R>(self, pred: P) -> TakeWhile<Self, P, R> where
P: FnMut(&Self::Item) -> R,
R: IntoFuture<Item = bool, Error = Self::Error>,
[src]
fn take_while<P, R>(self, pred: P) -> TakeWhile<Self, P, R> where
P: FnMut(&Self::Item) -> R,
R: IntoFuture<Item = bool, Error = Self::Error>,
Take elements from this stream while the predicate provided resolves to true
. Read more
fn for_each<F, U>(self, f: F) -> ForEach<Self, F, U> where
F: FnMut(Self::Item) -> U,
U: IntoFuture<Item = (), Error = Self::Error>,
[src]
fn for_each<F, U>(self, f: F) -> ForEach<Self, F, U> where
F: FnMut(Self::Item) -> U,
U: IntoFuture<Item = (), Error = Self::Error>,
Runs this stream to completion, executing the provided closure for each element on the stream. Read more
fn from_err<E>(self) -> FromErr<Self, E> where
E: From<Self::Error>,
[src]
fn from_err<E>(self) -> FromErr<Self, E> where
E: From<Self::Error>,
Map this stream's error to any error implementing From
for this stream's Error
, returning a new stream. Read more
fn take(self, amt: u64) -> Take<Self>
[src]
fn take(self, amt: u64) -> Take<Self>
Creates a new stream of at most amt
items of the underlying stream. Read more
fn skip(self, amt: u64) -> Skip<Self>
[src]
fn skip(self, amt: u64) -> Skip<Self>
Creates a new stream which skips amt
items of the underlying stream. Read more
fn fuse(self) -> Fuse<Self>
[src]
fn fuse(self) -> Fuse<Self>
Fuse a stream such that poll
will never again be called once it has finished. Read more
fn by_ref(&mut self) -> &mut Self
[src]
fn by_ref(&mut self) -> &mut Self
Borrows a stream, rather than consuming it. Read more
fn catch_unwind(self) -> CatchUnwind<Self> where
Self: UnwindSafe,
[src]
fn catch_unwind(self) -> CatchUnwind<Self> where
Self: UnwindSafe,
Catches unwinding panics while polling the stream. Read more
fn buffered(self, amt: usize) -> Buffered<Self> where
Self::Item: IntoFuture,
<Self::Item as IntoFuture>::Error == Self::Error,
[src]
fn buffered(self, amt: usize) -> Buffered<Self> where
Self::Item: IntoFuture,
<Self::Item as IntoFuture>::Error == Self::Error,
An adaptor for creating a buffered list of pending futures. Read more
fn buffer_unordered(self, amt: usize) -> BufferUnordered<Self> where
Self::Item: IntoFuture,
<Self::Item as IntoFuture>::Error == Self::Error,
[src]
fn buffer_unordered(self, amt: usize) -> BufferUnordered<Self> where
Self::Item: IntoFuture,
<Self::Item as IntoFuture>::Error == Self::Error,
An adaptor for creating a buffered list of pending futures (unordered). Read more
fn merge<S>(self, other: S) -> Merge<Self, S> where
S: Stream<Error = Self::Error>,
[src]
fn merge<S>(self, other: S) -> Merge<Self, S> where
S: Stream<Error = Self::Error>,
: functionality provided by select
now
An adapter for merging the output of two streams. Read more
fn zip<S>(self, other: S) -> Zip<Self, S> where
S: Stream<Error = Self::Error>,
[src]
fn zip<S>(self, other: S) -> Zip<Self, S> where
S: Stream<Error = Self::Error>,
An adapter for zipping two streams together. Read more
fn chain<S>(self, other: S) -> Chain<Self, S> where
S: Stream<Item = Self::Item, Error = Self::Error>,
[src]
fn chain<S>(self, other: S) -> Chain<Self, S> where
S: Stream<Item = Self::Item, Error = Self::Error>,
Adapter for chaining two stream. Read more
fn peekable(self) -> Peekable<Self>
[src]
fn peekable(self) -> Peekable<Self>
Creates a new stream which exposes a peek
method. Read more
fn chunks(self, capacity: usize) -> Chunks<Self>
[src]
fn chunks(self, capacity: usize) -> Chunks<Self>
An adaptor for chunking up items of the stream inside a vector. Read more
fn select<S>(self, other: S) -> Select<Self, S> where
S: Stream<Item = Self::Item, Error = Self::Error>,
[src]
fn select<S>(self, other: S) -> Select<Self, S> where
S: Stream<Item = Self::Item, Error = Self::Error>,
Creates a stream that selects the next element from either this stream or the provided one, whichever is ready first. Read more
fn forward<S>(self, sink: S) -> Forward<Self, S> where
S: Sink<SinkItem = Self::Item>,
Self::Error: From<<S as Sink>::SinkError>,
[src]
fn forward<S>(self, sink: S) -> Forward<Self, S> where
S: Sink<SinkItem = Self::Item>,
Self::Error: From<<S as Sink>::SinkError>,
A future that completes after the given stream has been fully processed into the sink, including flushing. Read more
fn split(self) -> (SplitSink<Self>, SplitStream<Self>) where
Self: Sink,
[src]
fn split(self) -> (SplitSink<Self>, SplitStream<Self>) where
Self: Sink,
Splits this Stream + Sink
object into separate Stream
and Sink
objects. Read more
fn inspect<F>(self, f: F) -> Inspect<Self, F> where
F: FnMut(&Self::Item),
[src]
fn inspect<F>(self, f: F) -> Inspect<Self, F> where
F: FnMut(&Self::Item),
Do something with each item of this stream, afterwards passing it on. Read more
fn inspect_err<F>(self, f: F) -> InspectErr<Self, F> where
F: FnMut(&Self::Error),
[src]
fn inspect_err<F>(self, f: F) -> InspectErr<Self, F> where
F: FnMut(&Self::Error),
Do something with the error of this stream, afterwards passing it on. Read more
impl<R> AsyncRead for Compat<R> where
R: AsyncRead,
[src]
impl<R> AsyncRead for Compat<R> where
R: AsyncRead,
unsafe fn prepare_uninitialized_buffer(&self, buf: &mut [u8]) -> bool
[src]
unsafe fn prepare_uninitialized_buffer(&self, buf: &mut [u8]) -> bool
Prepares an uninitialized buffer to be safe to pass to read
. Returns true
if the supplied buffer was zeroed out. Read more
fn poll_read(&mut self, buf: &mut [u8]) -> Result<Async<usize>, Error>
[src]
fn poll_read(&mut self, buf: &mut [u8]) -> Result<Async<usize>, Error>
Attempt to read from the AsyncRead
into buf
. Read more
fn read_buf<B>(&mut self, buf: &mut B) -> Result<Async<usize>, Error> where
B: BufMut,
[src]
fn read_buf<B>(&mut self, buf: &mut B) -> Result<Async<usize>, Error> where
B: BufMut,
Pull some bytes from this source into the specified Buf
, returning how many bytes were read. Read more
fn framed<T>(self, codec: T) -> Framed<Self, T> where
Self: AsyncWrite,
T: Decoder + Encoder,
[src]
fn framed<T>(self, codec: T) -> Framed<Self, T> where
Self: AsyncWrite,
T: Decoder + Encoder,
: Use tokio_codec::Decoder::framed instead
Provides a Stream
and Sink
interface for reading and writing to this Io
object, using Decode
and Encode
to read and write the raw data. Read more
fn split(self) -> (ReadHalf<Self>, WriteHalf<Self>) where
Self: AsyncWrite,
[src]
fn split(self) -> (ReadHalf<Self>, WriteHalf<Self>) where
Self: AsyncWrite,
Helper method for splitting this read/write object into two halves. Read more
impl<R> Read for Compat<R> where
R: AsyncRead,
[src]
impl<R> Read for Compat<R> where
R: AsyncRead,
fn read(&mut self, buf: &mut [u8]) -> Result<usize, Error>
[src]
fn read(&mut self, buf: &mut [u8]) -> Result<usize, Error>
Pull some bytes from this source into the specified buffer, returning how many bytes were read. Read more
unsafe fn initializer(&self) -> Initializer
[src]
unsafe fn initializer(&self) -> Initializer
read_initializer
)Determines if this Read
er can work with buffers of uninitialized memory. Read more
fn read_to_end(&mut self, buf: &mut Vec<u8>) -> Result<usize, Error>
1.0.0[src]
fn read_to_end(&mut self, buf: &mut Vec<u8>) -> Result<usize, Error>
Read all bytes until EOF in this source, placing them into buf
. Read more
fn read_to_string(&mut self, buf: &mut String) -> Result<usize, Error>
1.0.0[src]
fn read_to_string(&mut self, buf: &mut String) -> Result<usize, Error>
Read all bytes until EOF in this source, appending them to buf
. Read more
fn read_exact(&mut self, buf: &mut [u8]) -> Result<(), Error>
1.6.0[src]
fn read_exact(&mut self, buf: &mut [u8]) -> Result<(), Error>
Read the exact number of bytes required to fill buf
. Read more
fn by_ref(&mut self) -> &mut Self
1.0.0[src]
fn by_ref(&mut self) -> &mut Self
Creates a "by reference" adaptor for this instance of Read
. Read more
fn bytes(self) -> Bytes<Self>
1.0.0[src]
fn bytes(self) -> Bytes<Self>
Transforms this Read
instance to an [Iterator
] over its bytes. Read more
fn chain<R>(self, next: R) -> Chain<Self, R> where
R: Read,
1.0.0[src]
fn chain<R>(self, next: R) -> Chain<Self, R> where
R: Read,
Creates an adaptor which will chain this stream with another. Read more
fn take(self, limit: u64) -> Take<Self>
1.0.0[src]
fn take(self, limit: u64) -> Take<Self>
Creates an adaptor which will read at most limit
bytes from it. Read more
impl<T> Debug for Compat<T> where
T: Debug,
[src]
impl<T> Debug for Compat<T> where
T: Debug,
fn fmt(&self, f: &mut Formatter) -> Result<(), Error>
[src]
fn fmt(&self, f: &mut Formatter) -> Result<(), Error>
Formats the value using the given formatter. Read more
impl<W> AsyncWrite for Compat<W> where
W: AsyncWrite,
[src]
impl<W> AsyncWrite for Compat<W> where
W: AsyncWrite,
fn shutdown(&mut self) -> Result<Async<()>, Error>
[src]
fn shutdown(&mut self) -> Result<Async<()>, Error>
Initiates or attempts to shut down this writer, returning success when the I/O connection has completely shut down. Read more
fn poll_write(&mut self, buf: &[u8]) -> Result<Async<usize>, Error>
[src]
fn poll_write(&mut self, buf: &[u8]) -> Result<Async<usize>, Error>
Attempt to write bytes from buf
into the object. Read more
fn poll_flush(&mut self) -> Result<Async<()>, Error>
[src]
fn poll_flush(&mut self) -> Result<Async<()>, Error>
Attempt to flush the object, ensuring that any buffered data reach their destination. Read more
fn write_buf<B>(&mut self, buf: &mut B) -> Result<Async<usize>, Error> where
B: Buf,
[src]
fn write_buf<B>(&mut self, buf: &mut B) -> Result<Async<usize>, Error> where
B: Buf,
Write a Buf
into this value, returning how many bytes were written. Read more
impl<W> Write for Compat<W> where
W: AsyncWrite,
[src]
impl<W> Write for Compat<W> where
W: AsyncWrite,
fn write(&mut self, buf: &[u8]) -> Result<usize, Error>
[src]
fn write(&mut self, buf: &[u8]) -> Result<usize, Error>
Write a buffer into this object, returning how many bytes were written. Read more
fn flush(&mut self) -> Result<(), Error>
[src]
fn flush(&mut self) -> Result<(), Error>
Flush this output stream, ensuring that all intermediately buffered contents reach their destination. Read more
fn write_all(&mut self, buf: &[u8]) -> Result<(), Error>
1.0.0[src]
fn write_all(&mut self, buf: &[u8]) -> Result<(), Error>
Attempts to write an entire buffer into this write. Read more
fn write_fmt(&mut self, fmt: Arguments) -> Result<(), Error>
1.0.0[src]
fn write_fmt(&mut self, fmt: Arguments) -> Result<(), Error>
Writes a formatted string into this writer, returning any error encountered. Read more
fn by_ref(&mut self) -> &mut Self
1.0.0[src]
fn by_ref(&mut self) -> &mut Self
Creates a "by reference" adaptor for this instance of Write
. Read more
impl<Fut> Future for Compat<Fut> where
Fut: TryFuture + Unpin,
[src]
impl<Fut> Future for Compat<Fut> where
Fut: TryFuture + Unpin,
type Item = <Fut as TryFuture>::Ok
The type of value that this future will resolved with if it is successful. Read more
type Error = <Fut as TryFuture>::Error
The type of error that this future will resolve with if it fails in a normal fashion. Read more
fn poll(
&mut self
) -> Result<Async<<Compat<Fut> as Future>::Item>, <Compat<Fut> as Future>::Error>
[src]
fn poll(
&mut self
) -> Result<Async<<Compat<Fut> as Future>::Item>, <Compat<Fut> as Future>::Error>
Query this future to see if its value has become available, registering interest if it is not. Read more
fn wait(self) -> Result<Self::Item, Self::Error>
[src]
fn wait(self) -> Result<Self::Item, Self::Error>
Block the current thread until this future is resolved. Read more
fn map<F, U>(self, f: F) -> Map<Self, F> where
F: FnOnce(Self::Item) -> U,
[src]
fn map<F, U>(self, f: F) -> Map<Self, F> where
F: FnOnce(Self::Item) -> U,
Map this future's result to a different type, returning a new future of the resulting type. Read more
fn map_err<F, E>(self, f: F) -> MapErr<Self, F> where
F: FnOnce(Self::Error) -> E,
[src]
fn map_err<F, E>(self, f: F) -> MapErr<Self, F> where
F: FnOnce(Self::Error) -> E,
Map this future's error to a different error, returning a new future. Read more
fn from_err<E>(self) -> FromErr<Self, E> where
E: From<Self::Error>,
[src]
fn from_err<E>(self) -> FromErr<Self, E> where
E: From<Self::Error>,
Map this future's error to any error implementing From
for this future's Error
, returning a new future. Read more
fn then<F, B>(self, f: F) -> Then<Self, B, F> where
B: IntoFuture,
F: FnOnce(Result<Self::Item, Self::Error>) -> B,
[src]
fn then<F, B>(self, f: F) -> Then<Self, B, F> where
B: IntoFuture,
F: FnOnce(Result<Self::Item, Self::Error>) -> B,
Chain on a computation for when a future finished, passing the result of the future to the provided closure f
. Read more
fn and_then<F, B>(self, f: F) -> AndThen<Self, B, F> where
B: IntoFuture<Error = Self::Error>,
F: FnOnce(Self::Item) -> B,
[src]
fn and_then<F, B>(self, f: F) -> AndThen<Self, B, F> where
B: IntoFuture<Error = Self::Error>,
F: FnOnce(Self::Item) -> B,
Execute another future after this one has resolved successfully. Read more
fn or_else<F, B>(self, f: F) -> OrElse<Self, B, F> where
B: IntoFuture<Item = Self::Item>,
F: FnOnce(Self::Error) -> B,
[src]
fn or_else<F, B>(self, f: F) -> OrElse<Self, B, F> where
B: IntoFuture<Item = Self::Item>,
F: FnOnce(Self::Error) -> B,
Execute another future if this one resolves with an error. Read more
fn select<B>(self, other: B) -> Select<Self, <B as IntoFuture>::Future> where
B: IntoFuture<Item = Self::Item, Error = Self::Error>,
[src]
fn select<B>(self, other: B) -> Select<Self, <B as IntoFuture>::Future> where
B: IntoFuture<Item = Self::Item, Error = Self::Error>,
Waits for either one of two futures to complete. Read more
fn select2<B>(self, other: B) -> Select2<Self, <B as IntoFuture>::Future> where
B: IntoFuture,
[src]
fn select2<B>(self, other: B) -> Select2<Self, <B as IntoFuture>::Future> where
B: IntoFuture,
Waits for either one of two differently-typed futures to complete. Read more
fn join<B>(self, other: B) -> Join<Self, <B as IntoFuture>::Future> where
B: IntoFuture<Error = Self::Error>,
[src]
fn join<B>(self, other: B) -> Join<Self, <B as IntoFuture>::Future> where
B: IntoFuture<Error = Self::Error>,
Joins the result of two futures, waiting for them both to complete. Read more
fn join3<B, C>(
self,
b: B,
c: C
) -> Join3<Self, <B as IntoFuture>::Future, <C as IntoFuture>::Future> where
B: IntoFuture<Error = Self::Error>,
C: IntoFuture<Error = Self::Error>,
[src]
fn join3<B, C>(
self,
b: B,
c: C
) -> Join3<Self, <B as IntoFuture>::Future, <C as IntoFuture>::Future> where
B: IntoFuture<Error = Self::Error>,
C: IntoFuture<Error = Self::Error>,
Same as join
, but with more futures.
fn join4<B, C, D>(
self,
b: B,
c: C,
d: D
) -> Join4<Self, <B as IntoFuture>::Future, <C as IntoFuture>::Future, <D as IntoFuture>::Future> where
B: IntoFuture<Error = Self::Error>,
C: IntoFuture<Error = Self::Error>,
D: IntoFuture<Error = Self::Error>,
[src]
fn join4<B, C, D>(
self,
b: B,
c: C,
d: D
) -> Join4<Self, <B as IntoFuture>::Future, <C as IntoFuture>::Future, <D as IntoFuture>::Future> where
B: IntoFuture<Error = Self::Error>,
C: IntoFuture<Error = Self::Error>,
D: IntoFuture<Error = Self::Error>,
Same as join
, but with more futures.
fn join5<B, C, D, E>(
self,
b: B,
c: C,
d: D,
e: E
) -> Join5<Self, <B as IntoFuture>::Future, <C as IntoFuture>::Future, <D as IntoFuture>::Future, <E as IntoFuture>::Future> where
B: IntoFuture<Error = Self::Error>,
C: IntoFuture<Error = Self::Error>,
D: IntoFuture<Error = Self::Error>,
E: IntoFuture<Error = Self::Error>,
[src]
fn join5<B, C, D, E>(
self,
b: B,
c: C,
d: D,
e: E
) -> Join5<Self, <B as IntoFuture>::Future, <C as IntoFuture>::Future, <D as IntoFuture>::Future, <E as IntoFuture>::Future> where
B: IntoFuture<Error = Self::Error>,
C: IntoFuture<Error = Self::Error>,
D: IntoFuture<Error = Self::Error>,
E: IntoFuture<Error = Self::Error>,
Same as join
, but with more futures.
fn into_stream(self) -> IntoStream<Self>
[src]
fn into_stream(self) -> IntoStream<Self>
Convert this future into a single element stream. Read more
fn flatten(self) -> Flatten<Self> where
Self::Item: IntoFuture,
<Self::Item as IntoFuture>::Error: From<Self::Error>,
[src]
fn flatten(self) -> Flatten<Self> where
Self::Item: IntoFuture,
<Self::Item as IntoFuture>::Error: From<Self::Error>,
Flatten the execution of this future when the successful result of this future is itself another future. Read more
fn flatten_stream(self) -> FlattenStream<Self> where
Self::Item: Stream,
<Self::Item as Stream>::Error == Self::Error,
[src]
fn flatten_stream(self) -> FlattenStream<Self> where
Self::Item: Stream,
<Self::Item as Stream>::Error == Self::Error,
Flatten the execution of this future when the successful result of this future is a stream. Read more
fn fuse(self) -> Fuse<Self>
[src]
fn fuse(self) -> Fuse<Self>
Fuse a future such that poll
will never again be called once it has completed. Read more
fn inspect<F>(self, f: F) -> Inspect<Self, F> where
F: FnOnce(&Self::Item),
[src]
fn inspect<F>(self, f: F) -> Inspect<Self, F> where
F: FnOnce(&Self::Item),
Do something with the item of a future, passing it on. Read more
fn catch_unwind(self) -> CatchUnwind<Self> where
Self: UnwindSafe,
[src]
fn catch_unwind(self) -> CatchUnwind<Self> where
Self: UnwindSafe,
Catches unwinding panics while polling the future. Read more
Create a cloneable handle to this future where all handles will resolve to the same result. Read more
impl<T> Sink for Compat<T> where
T: Sink + Unpin,
[src]
impl<T> Sink for Compat<T> where
T: Sink + Unpin,
type SinkItem = <T as Sink>::SinkItem
The type of value that the sink accepts.
type SinkError = <T as Sink>::SinkError
The type of value produced by the sink when an error occurs.
fn start_send(
&mut self,
item: <Compat<T> as Sink>::SinkItem
) -> Result<AsyncSink<<Compat<T> as Sink>::SinkItem>, <Compat<T> as Sink>::SinkError>
[src]
fn start_send(
&mut self,
item: <Compat<T> as Sink>::SinkItem
) -> Result<AsyncSink<<Compat<T> as Sink>::SinkItem>, <Compat<T> as Sink>::SinkError>
Begin the process of sending a value to the sink. Read more
fn poll_complete(&mut self) -> Result<Async<()>, <Compat<T> as Sink>::SinkError>
[src]
fn poll_complete(&mut self) -> Result<Async<()>, <Compat<T> as Sink>::SinkError>
Flush all output from this sink, if necessary. Read more
fn close(&mut self) -> Result<Async<()>, <Compat<T> as Sink>::SinkError>
[src]
fn close(&mut self) -> Result<Async<()>, <Compat<T> as Sink>::SinkError>
A method to indicate that no more values will ever be pushed into this sink. Read more
fn wait(self) -> Wait<Self>
[src]
fn wait(self) -> Wait<Self>
Creates a new object which will produce a synchronous sink. Read more
fn with<U, F, Fut>(self, f: F) -> With<Self, U, F, Fut> where
F: FnMut(U) -> Fut,
Fut: IntoFuture<Item = Self::SinkItem>,
<Fut as IntoFuture>::Error: From<Self::SinkError>,
[src]
fn with<U, F, Fut>(self, f: F) -> With<Self, U, F, Fut> where
F: FnMut(U) -> Fut,
Fut: IntoFuture<Item = Self::SinkItem>,
<Fut as IntoFuture>::Error: From<Self::SinkError>,
Composes a function in front of the sink. Read more
fn with_flat_map<U, F, St>(self, f: F) -> WithFlatMap<Self, U, F, St> where
F: FnMut(U) -> St,
St: Stream<Item = Self::SinkItem, Error = Self::SinkError>,
[src]
fn with_flat_map<U, F, St>(self, f: F) -> WithFlatMap<Self, U, F, St> where
F: FnMut(U) -> St,
St: Stream<Item = Self::SinkItem, Error = Self::SinkError>,
Composes a function in front of the sink. Read more
fn sink_map_err<F, E>(self, f: F) -> SinkMapErr<Self, F> where
F: FnOnce(Self::SinkError) -> E,
[src]
fn sink_map_err<F, E>(self, f: F) -> SinkMapErr<Self, F> where
F: FnOnce(Self::SinkError) -> E,
Transforms the error returned by the sink.
fn sink_from_err<E>(self) -> SinkFromErr<Self, E> where
E: From<Self::SinkError>,
[src]
fn sink_from_err<E>(self) -> SinkFromErr<Self, E> where
E: From<Self::SinkError>,
Map this sink's error to any error implementing From
for this sink's Error
, returning a new sink. Read more
fn buffer(self, amt: usize) -> Buffer<Self>
[src]
fn buffer(self, amt: usize) -> Buffer<Self>
Adds a fixed-size buffer to the current sink. Read more
fn fanout<S>(self, other: S) -> Fanout<Self, S> where
S: Sink<SinkItem = Self::SinkItem, SinkError = Self::SinkError>,
Self::SinkItem: Clone,
[src]
fn fanout<S>(self, other: S) -> Fanout<Self, S> where
S: Sink<SinkItem = Self::SinkItem, SinkError = Self::SinkError>,
Self::SinkItem: Clone,
Fanout items to multiple sinks. Read more
fn flush(self) -> Flush<Self>
[src]
fn flush(self) -> Flush<Self>
A future that completes when the sink has finished processing all pending requests. Read more
fn send(self, item: Self::SinkItem) -> Send<Self>
[src]
fn send(self, item: Self::SinkItem) -> Send<Self>
A future that completes after the given item has been fully processed into the sink, including flushing. Read more
fn send_all<S>(self, stream: S) -> SendAll<Self, S> where
S: Stream<Item = Self::SinkItem>,
Self::SinkError: From<<S as Stream>::Error>,
[src]
fn send_all<S>(self, stream: S) -> SendAll<Self, S> where
S: Stream<Item = Self::SinkItem>,
Self::SinkError: From<<S as Stream>::Error>,
A future that completes after the given stream has been fully processed into the sink, including flushing. Read more
impl<Sp, Fut> Executor<Fut> for Compat<Sp> where
Fut: Future<Item = (), Error = ()> + Send + 'static,
&'a Sp: Spawn,
[src]
impl<Sp, Fut> Executor<Fut> for Compat<Sp> where
Fut: Future<Item = (), Error = ()> + Send + 'static,
&'a Sp: Spawn,
Auto Trait Implementations
Blanket Implementations
impl<T, U> Into for T where
U: From<T>,
[src]
impl<T, U> Into for T where
U: From<T>,
impl<T> From for T
[src]
impl<T> From for T
impl<T, U> TryFrom for T where
T: From<U>,
[src]
impl<T, U> TryFrom for T where
T: From<U>,
type Error = !
try_from
)The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
try_from
)Performs the conversion.
impl<T> Borrow for T where
T: ?Sized,
[src]
impl<T> Borrow for T where
T: ?Sized,
impl<T> Any for T where
T: 'static + ?Sized,
[src]
impl<T> Any for T where
T: 'static + ?Sized,
fn get_type_id(&self) -> TypeId
[src]
fn get_type_id(&self) -> TypeId
🔬 This is a nightly-only experimental API. (get_type_id
)
this method will likely be replaced by an associated static
Gets the TypeId
of self
. Read more
impl<T> BorrowMut for T where
T: ?Sized,
[src]
impl<T> BorrowMut for T where
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
impl<T, U> TryInto for T where
U: TryFrom<T>,
[src]
impl<T, U> TryInto for T where
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
try_from
)The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
try_from
)Performs the conversion.
impl<Fut> Future01CompatExt for Fut where
Fut: Future,
[src]
impl<Fut> Future01CompatExt for Fut where
Fut: Future,
fn compat(self) -> Compat01As03<Self>
[src]
fn compat(self) -> Compat01As03<Self>
Converts a futures 0.1 Future<Item = T, Error = E>
into a futures 0.3 Future<Output = Result<T, E>>
. Read more
impl<St> Stream01CompatExt for St where
St: Stream,
[src]
impl<St> Stream01CompatExt for St where
St: Stream,
fn compat(self) -> Compat01As03<Self>
[src]
fn compat(self) -> Compat01As03<Self>
Converts a futures 0.1 Stream<Item = T, Error = E>
into a futures 0.3 Stream<Item = Result<T, E>>
. Read more
impl<F> IntoFuture for F where
F: Future,
[src]
impl<F> IntoFuture for F where
F: Future,
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.
fn into_future(self) -> F
[src]
fn into_future(self) -> F
Consumes this object and produces a future.
impl<R> ReadBytesExt for R where
R: Read + ?Sized,
impl<R> ReadBytesExt for R where
R: Read + ?Sized,
fn read_u8(&mut self) -> Result<u8, Error>
fn read_u8(&mut self) -> Result<u8, Error>
Reads an unsigned 8 bit integer from the underlying reader. Read more
fn read_i8(&mut self) -> Result<i8, Error>
fn read_i8(&mut self) -> Result<i8, Error>
Reads a signed 8 bit integer from the underlying reader. Read more
fn read_u16<T>(&mut self) -> Result<u16, Error> where
T: ByteOrder,
fn read_u16<T>(&mut self) -> Result<u16, Error> where
T: ByteOrder,
Reads an unsigned 16 bit integer from the underlying reader. Read more
fn read_i16<T>(&mut self) -> Result<i16, Error> where
T: ByteOrder,
fn read_i16<T>(&mut self) -> Result<i16, Error> where
T: ByteOrder,
Reads a signed 16 bit integer from the underlying reader. Read more
fn read_u24<T>(&mut self) -> Result<u32, Error> where
T: ByteOrder,
fn read_u24<T>(&mut self) -> Result<u32, Error> where
T: ByteOrder,
Reads an unsigned 24 bit integer from the underlying reader. Read more
fn read_i24<T>(&mut self) -> Result<i32, Error> where
T: ByteOrder,
fn read_i24<T>(&mut self) -> Result<i32, Error> where
T: ByteOrder,
Reads a signed 24 bit integer from the underlying reader. Read more
fn read_u32<T>(&mut self) -> Result<u32, Error> where
T: ByteOrder,
fn read_u32<T>(&mut self) -> Result<u32, Error> where
T: ByteOrder,
Reads an unsigned 32 bit integer from the underlying reader. Read more
fn read_i32<T>(&mut self) -> Result<i32, Error> where
T: ByteOrder,
fn read_i32<T>(&mut self) -> Result<i32, Error> where
T: ByteOrder,
Reads a signed 32 bit integer from the underlying reader. Read more
fn read_u48<T>(&mut self) -> Result<u64, Error> where
T: ByteOrder,
fn read_u48<T>(&mut self) -> Result<u64, Error> where
T: ByteOrder,
Reads an unsigned 48 bit integer from the underlying reader. Read more
fn read_i48<T>(&mut self) -> Result<i64, Error> where
T: ByteOrder,
fn read_i48<T>(&mut self) -> Result<i64, Error> where
T: ByteOrder,
Reads a signed 48 bit integer from the underlying reader. Read more
fn read_u64<T>(&mut self) -> Result<u64, Error> where
T: ByteOrder,
fn read_u64<T>(&mut self) -> Result<u64, Error> where
T: ByteOrder,
Reads an unsigned 64 bit integer from the underlying reader. Read more
fn read_i64<T>(&mut self) -> Result<i64, Error> where
T: ByteOrder,
fn read_i64<T>(&mut self) -> Result<i64, Error> where
T: ByteOrder,
Reads a signed 64 bit integer from the underlying reader. Read more
fn read_uint<T>(&mut self, nbytes: usize) -> Result<u64, Error> where
T: ByteOrder,
fn read_uint<T>(&mut self, nbytes: usize) -> Result<u64, Error> where
T: ByteOrder,
Reads an unsigned n-bytes integer from the underlying reader. Read more
fn read_int<T>(&mut self, nbytes: usize) -> Result<i64, Error> where
T: ByteOrder,
fn read_int<T>(&mut self, nbytes: usize) -> Result<i64, Error> where
T: ByteOrder,
Reads a signed n-bytes integer from the underlying reader. Read more
fn read_f32<T>(&mut self) -> Result<f32, Error> where
T: ByteOrder,
fn read_f32<T>(&mut self) -> Result<f32, Error> where
T: ByteOrder,
Reads a IEEE754 single-precision (4 bytes) floating point number from the underlying reader. Read more
fn read_f64<T>(&mut self) -> Result<f64, Error> where
T: ByteOrder,
fn read_f64<T>(&mut self) -> Result<f64, Error> where
T: ByteOrder,
Reads a IEEE754 double-precision (8 bytes) floating point number from the underlying reader. Read more
fn read_u16_into<T>(&mut self, dst: &mut [u16]) -> Result<(), Error> where
T: ByteOrder,
fn read_u16_into<T>(&mut self, dst: &mut [u16]) -> Result<(), Error> where
T: ByteOrder,
Reads a sequence of unsigned 16 bit integers from the underlying reader. Read more
fn read_u32_into<T>(&mut self, dst: &mut [u32]) -> Result<(), Error> where
T: ByteOrder,
fn read_u32_into<T>(&mut self, dst: &mut [u32]) -> Result<(), Error> where
T: ByteOrder,
Reads a sequence of unsigned 32 bit integers from the underlying reader. Read more
fn read_u64_into<T>(&mut self, dst: &mut [u64]) -> Result<(), Error> where
T: ByteOrder,
fn read_u64_into<T>(&mut self, dst: &mut [u64]) -> Result<(), Error> where
T: ByteOrder,
Reads a sequence of unsigned 64 bit integers from the underlying reader. Read more
fn read_i16_into<T>(&mut self, dst: &mut [i16]) -> Result<(), Error> where
T: ByteOrder,
fn read_i16_into<T>(&mut self, dst: &mut [i16]) -> Result<(), Error> where
T: ByteOrder,
Reads a sequence of signed 16 bit integers from the underlying reader. Read more
fn read_i32_into<T>(&mut self, dst: &mut [i32]) -> Result<(), Error> where
T: ByteOrder,
fn read_i32_into<T>(&mut self, dst: &mut [i32]) -> Result<(), Error> where
T: ByteOrder,
Reads a sequence of signed 32 bit integers from the underlying reader. Read more
fn read_i64_into<T>(&mut self, dst: &mut [i64]) -> Result<(), Error> where
T: ByteOrder,
fn read_i64_into<T>(&mut self, dst: &mut [i64]) -> Result<(), Error> where
T: ByteOrder,
Reads a sequence of signed 64 bit integers from the underlying reader. Read more
fn read_f32_into<T>(&mut self, dst: &mut [f32]) -> Result<(), Error> where
T: ByteOrder,
fn read_f32_into<T>(&mut self, dst: &mut [f32]) -> Result<(), Error> where
T: ByteOrder,
Reads a sequence of IEEE754 single-precision (4 bytes) floating point numbers from the underlying reader. Read more
fn read_f32_into_unchecked<T>(&mut self, dst: &mut [f32]) -> Result<(), Error> where
T: ByteOrder,
fn read_f32_into_unchecked<T>(&mut self, dst: &mut [f32]) -> Result<(), Error> where
T: ByteOrder,
: please use read_f32_into
instead
DEPRECATED. Read more
fn read_f64_into<T>(&mut self, dst: &mut [f64]) -> Result<(), Error> where
T: ByteOrder,
fn read_f64_into<T>(&mut self, dst: &mut [f64]) -> Result<(), Error> where
T: ByteOrder,
Reads a sequence of IEEE754 double-precision (8 bytes) floating point numbers from the underlying reader. Read more
fn read_f64_into_unchecked<T>(&mut self, dst: &mut [f64]) -> Result<(), Error> where
T: ByteOrder,
fn read_f64_into_unchecked<T>(&mut self, dst: &mut [f64]) -> Result<(), Error> where
T: ByteOrder,
: please use read_f64_into
instead
DEPRECATED. Read more
impl<W> WriteBytesExt for W where
W: Write + ?Sized,
impl<W> WriteBytesExt for W where
W: Write + ?Sized,
fn write_u8(&mut self, n: u8) -> Result<(), Error>
fn write_u8(&mut self, n: u8) -> Result<(), Error>
Writes an unsigned 8 bit integer to the underlying writer. Read more
fn write_i8(&mut self, n: i8) -> Result<(), Error>
fn write_i8(&mut self, n: i8) -> Result<(), Error>
Writes a signed 8 bit integer to the underlying writer. Read more
fn write_u16<T>(&mut self, n: u16) -> Result<(), Error> where
T: ByteOrder,
fn write_u16<T>(&mut self, n: u16) -> Result<(), Error> where
T: ByteOrder,
Writes an unsigned 16 bit integer to the underlying writer. Read more
fn write_i16<T>(&mut self, n: i16) -> Result<(), Error> where
T: ByteOrder,
fn write_i16<T>(&mut self, n: i16) -> Result<(), Error> where
T: ByteOrder,
Writes a signed 16 bit integer to the underlying writer. Read more
fn write_u24<T>(&mut self, n: u32) -> Result<(), Error> where
T: ByteOrder,
fn write_u24<T>(&mut self, n: u32) -> Result<(), Error> where
T: ByteOrder,
Writes an unsigned 24 bit integer to the underlying writer. Read more
fn write_i24<T>(&mut self, n: i32) -> Result<(), Error> where
T: ByteOrder,
fn write_i24<T>(&mut self, n: i32) -> Result<(), Error> where
T: ByteOrder,
Writes a signed 24 bit integer to the underlying writer. Read more
fn write_u32<T>(&mut self, n: u32) -> Result<(), Error> where
T: ByteOrder,
fn write_u32<T>(&mut self, n: u32) -> Result<(), Error> where
T: ByteOrder,
Writes an unsigned 32 bit integer to the underlying writer. Read more
fn write_i32<T>(&mut self, n: i32) -> Result<(), Error> where
T: ByteOrder,
fn write_i32<T>(&mut self, n: i32) -> Result<(), Error> where
T: ByteOrder,
Writes a signed 32 bit integer to the underlying writer. Read more
fn write_u48<T>(&mut self, n: u64) -> Result<(), Error> where
T: ByteOrder,
fn write_u48<T>(&mut self, n: u64) -> Result<(), Error> where
T: ByteOrder,
Writes an unsigned 48 bit integer to the underlying writer. Read more
fn write_i48<T>(&mut self, n: i64) -> Result<(), Error> where
T: ByteOrder,
fn write_i48<T>(&mut self, n: i64) -> Result<(), Error> where
T: ByteOrder,
Writes a signed 48 bit integer to the underlying writer. Read more
fn write_u64<T>(&mut self, n: u64) -> Result<(), Error> where
T: ByteOrder,
fn write_u64<T>(&mut self, n: u64) -> Result<(), Error> where
T: ByteOrder,
Writes an unsigned 64 bit integer to the underlying writer. Read more
fn write_i64<T>(&mut self, n: i64) -> Result<(), Error> where
T: ByteOrder,
fn write_i64<T>(&mut self, n: i64) -> Result<(), Error> where
T: ByteOrder,
Writes a signed 64 bit integer to the underlying writer. Read more
fn write_uint<T>(&mut self, n: u64, nbytes: usize) -> Result<(), Error> where
T: ByteOrder,
fn write_uint<T>(&mut self, n: u64, nbytes: usize) -> Result<(), Error> where
T: ByteOrder,
Writes an unsigned n-bytes integer to the underlying writer. Read more
fn write_int<T>(&mut self, n: i64, nbytes: usize) -> Result<(), Error> where
T: ByteOrder,
fn write_int<T>(&mut self, n: i64, nbytes: usize) -> Result<(), Error> where
T: ByteOrder,
Writes a signed n-bytes integer to the underlying writer. Read more
fn write_f32<T>(&mut self, n: f32) -> Result<(), Error> where
T: ByteOrder,
fn write_f32<T>(&mut self, n: f32) -> Result<(), Error> where
T: ByteOrder,
Writes a IEEE754 single-precision (4 bytes) floating point number to the underlying writer. Read more
fn write_f64<T>(&mut self, n: f64) -> Result<(), Error> where
T: ByteOrder,
fn write_f64<T>(&mut self, n: f64) -> Result<(), Error> where
T: ByteOrder,
Writes a IEEE754 double-precision (8 bytes) floating point number to the underlying writer. Read more