pub struct CompatSink<T, Item> { /* private fields */ }
Available on crate features
compat
and sink
only.Implementations§
source§impl<T, Item> CompatSink<T, Item>
impl<T, Item> CompatSink<T, Item>
Trait Implementations§
source§impl<T, Item> Sink for CompatSink<T, Item>
impl<T, Item> Sink for CompatSink<T, Item>
source§type SinkError = <T as Sink<Item>>::Error
type SinkError = <T as Sink<Item>>::Error
The type of value produced by the sink when an error occurs.
source§fn start_send(
&mut self,
item: Self::SinkItem,
) -> StartSend01<Self::SinkItem, Self::SinkError>
fn start_send( &mut self, item: Self::SinkItem, ) -> StartSend01<Self::SinkItem, Self::SinkError>
Begin the process of sending a value to the sink. Read more
source§fn poll_complete(&mut self) -> Poll01<(), Self::SinkError>
fn poll_complete(&mut self) -> Poll01<(), Self::SinkError>
Flush all output from this sink, if necessary. Read more
source§fn close(&mut self) -> Poll01<(), Self::SinkError>
fn close(&mut self) -> Poll01<(), Self::SinkError>
A method to indicate that no more values will ever be pushed into this
sink. Read more
source§fn wait(self) -> Wait<Self>where
Self: Sized,
fn wait(self) -> Wait<Self>where
Self: Sized,
Creates a new object which will produce a synchronous sink. Read more
source§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>,
Self: Sized,
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>,
Self: Sized,
Composes a function in front of the sink. Read more
source§fn with_flat_map<U, F, St>(self, f: F) -> WithFlatMap<Self, U, F, St>
fn with_flat_map<U, F, St>(self, f: F) -> WithFlatMap<Self, U, F, St>
Composes a function in front of the sink. Read more
source§fn sink_map_err<F, E>(self, f: F) -> SinkMapErr<Self, F>
fn sink_map_err<F, E>(self, f: F) -> SinkMapErr<Self, F>
Transforms the error returned by the sink.
source§fn sink_from_err<E>(self) -> SinkFromErr<Self, E>
fn sink_from_err<E>(self) -> SinkFromErr<Self, E>
Map this sink’s error to any error implementing
From
for this sink’s
Error
, returning a new sink. Read moresource§fn buffer(self, amt: usize) -> Buffer<Self>where
Self: Sized,
fn buffer(self, amt: usize) -> Buffer<Self>where
Self: Sized,
Adds a fixed-size buffer to the current sink. Read more
source§fn flush(self) -> Flush<Self>where
Self: Sized,
fn flush(self) -> Flush<Self>where
Self: Sized,
A future that completes when the sink has finished processing all
pending requests. Read more
Auto Trait Implementations§
impl<T, Item> Freeze for CompatSink<T, Item>where
T: Freeze,
impl<T, Item> RefUnwindSafe for CompatSink<T, Item>where
T: RefUnwindSafe,
impl<T, Item> Send for CompatSink<T, Item>where
T: Send,
impl<T, Item> Sync for CompatSink<T, Item>where
T: Sync,
impl<T, Item> Unpin for CompatSink<T, Item>where
T: Unpin,
impl<T, Item> UnwindSafe for CompatSink<T, Item>where
T: UnwindSafe,
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
source§impl<Si> Sink01CompatExt for Siwhere
Si: Sink,
impl<Si> Sink01CompatExt for Siwhere
Si: Sink,
source§fn sink_compat(self) -> Compat01As03Sink<Self, Self::SinkItem>where
Self: Sized,
fn sink_compat(self) -> Compat01As03Sink<Self, Self::SinkItem>where
Self: Sized,
Available on crate features
compat
and sink
only.Converts a futures 0.1
Sink<SinkItem = T, SinkError = E>
into a futures 0.3
Sink<T, Error = E>
. Read more