pub struct Publisher<T: Send> { /* private fields */ }
Trait Implementations
sourceimpl<T: Send> Sink for Publisher<T>
impl<T: Send> Sink for Publisher<T>
type SinkItem = T
type SinkItem = T
The type of value that the sink accepts.
sourcefn start_send(
&mut self,
item: Self::SinkItem
) -> StartSend<Self::SinkItem, Self::SinkError>
fn start_send(
&mut self,
item: Self::SinkItem
) -> StartSend<Self::SinkItem, Self::SinkError>
Begin the process of sending a value to the sink. Read more
sourcefn poll_complete(&mut self) -> Poll<(), Self::SinkError>
fn poll_complete(&mut self) -> Poll<(), Self::SinkError>
Flush all output from this sink, if necessary. Read more
sourcefn close(&mut self) -> Poll<(), Self::SinkError>
fn close(&mut self) -> Poll<(), Self::SinkError>
A method to indicate that no more values will ever be pushed into this
sink. Read more
sourcefn 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
sourcefn 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
sourcefn 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>,
Self: Sized,
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>,
Self: Sized,
Composes a function in front of the sink. Read more
sourcefn sink_map_err<F, E>(self, f: F) -> SinkMapErr<Self, F>where
F: FnOnce(Self::SinkError) -> E,
Self: Sized,
fn sink_map_err<F, E>(self, f: F) -> SinkMapErr<Self, F>where
F: FnOnce(Self::SinkError) -> E,
Self: Sized,
Transforms the error returned by the sink.
sourcefn sink_from_err<E>(self) -> SinkFromErr<Self, E>where
E: From<Self::SinkError>,
Self: Sized,
fn sink_from_err<E>(self) -> SinkFromErr<Self, E>where
E: From<Self::SinkError>,
Self: Sized,
Map this sink’s error to any error implementing
From
for this sink’s
Error
, returning a new sink. Read moresourcefn 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
sourcefn 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> !RefUnwindSafe for Publisher<T>
impl<T> Send for Publisher<T>where
T: Sync,
impl<T> !Sync for Publisher<T>
impl<T> Unpin for Publisher<T>
impl<T> !UnwindSafe for Publisher<T>
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more