Trait SendStream

Source
pub trait SendStream<B>
where B: Buf,
{ // Required methods fn poll_ready( &mut self, cx: &mut Context<'_>, ) -> Poll<Result<(), StreamErrorIncoming>>; fn send_data<T>(&mut self, data: T) -> Result<(), StreamErrorIncoming> where T: Into<WriteBuf<B>>; fn poll_finish( &mut self, cx: &mut Context<'_>, ) -> Poll<Result<(), StreamErrorIncoming>>; fn reset(&mut self, reset_code: u64); fn send_id(&self) -> StreamId; }
Available on crate feature h3 only.
Expand description

A trait describing the “send” actions of a QUIC stream.

Required Methods§

Source

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

Polls if the stream can send more data.

Source

fn send_data<T>(&mut self, data: T) -> Result<(), StreamErrorIncoming>
where T: Into<WriteBuf<B>>,

Send more data on the stream.

Source

fn poll_finish( &mut self, cx: &mut Context<'_>, ) -> Poll<Result<(), StreamErrorIncoming>>

Poll to finish the sending side of the stream.

Source

fn reset(&mut self, reset_code: u64)

Send a QUIC reset code.

Source

fn send_id(&self) -> StreamId

Get QUIC send stream id

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§

Source§

impl<B> SendStream<B> for BidiStream<B>
where B: Buf,

Source§

impl<B> SendStream<B> for SendStream<B>
where B: Buf,

Source§

impl<S, B> SendStream<B> for BufRecvStream<S, B>
where B: Buf, S: SendStream<B>,

Source§

impl<T, B> SendStream<B> for FrameStream<T, B>
where T: SendStream<B>, B: Buf,