SinkVariadic

Trait SinkVariadic 

Source
pub trait SinkVariadic<Item, Error>: Variadic + Sealed<Item, Error> {
    // Required methods
    fn poll_ready(
        self: Pin<&mut Self>,
        cx: &mut Context<'_>,
    ) -> Poll<Result<(), Error>>;
    fn start_send(
        self: Pin<&mut Self>,
        idx: usize,
        item: Item,
    ) -> Result<(), Error>;
    fn poll_flush(
        self: Pin<&mut Self>,
        cx: &mut Context<'_>,
    ) -> Poll<Result<(), Error>>;
    fn poll_close(
        self: Pin<&mut Self>,
        cx: &mut Context<'_>,
    ) -> Poll<Result<(), Error>>;
}
Available on crate feature variadics only.
Expand description

A variadic of Sinks.

Used by DemuxVar.

Required Methods§

Source

fn poll_ready( self: Pin<&mut Self>, cx: &mut Context<'_>, ) -> Poll<Result<(), Error>>

Sink::poll_ready for all sinks.

Source

fn start_send(self: Pin<&mut Self>, idx: usize, item: Item) -> Result<(), Error>

Sink::start_send for the sink at index idx.

Source

fn poll_flush( self: Pin<&mut Self>, cx: &mut Context<'_>, ) -> Poll<Result<(), Error>>

Sink::poll_flush for all sinks.

Source

fn poll_close( self: Pin<&mut Self>, cx: &mut Context<'_>, ) -> Poll<Result<(), Error>>

Sink::poll_close for all sinks.

Implementations on Foreign Types§

Source§

impl<Item, Error> SinkVariadic<Item, Error> for ()

Source§

fn poll_ready( self: Pin<&mut Self>, _cx: &mut Context<'_>, ) -> Poll<Result<(), Error>>

Source§

fn start_send( self: Pin<&mut Self>, idx: usize, _item: Item, ) -> Result<(), Error>

Source§

fn poll_flush( self: Pin<&mut Self>, _cx: &mut Context<'_>, ) -> Poll<Result<(), Error>>

Source§

fn poll_close( self: Pin<&mut Self>, _cx: &mut Context<'_>, ) -> Poll<Result<(), Error>>

Source§

impl<Si, Item, Rest> SinkVariadic<Item, <Si as Sink<Item>>::Error> for (Si, Rest)
where Si: Sink<Item>, Rest: SinkVariadic<Item, Si::Error>,

Source§

fn poll_ready( self: Pin<&mut Self>, cx: &mut Context<'_>, ) -> Poll<Result<(), Si::Error>>

Source§

fn start_send( self: Pin<&mut Self>, idx: usize, item: Item, ) -> Result<(), Si::Error>

Source§

fn poll_flush( self: Pin<&mut Self>, cx: &mut Context<'_>, ) -> Poll<Result<(), Si::Error>>

Source§

fn poll_close( self: Pin<&mut Self>, cx: &mut Context<'_>, ) -> Poll<Result<(), Si::Error>>

Implementors§