Skip to main content

BytesFramed

Type Alias BytesFramed 

Source
pub type BytesFramed<R, W> = Framed<R, W, BytesCodec, NoopFramer, Bytes, Bytes>;
Available on crate feature bytes only.
Expand description

Framed that bridges AsyncRead/AsyncWrite with Bytes.

This is useful when you want to read/write raw bytes into/from Bytes without any additional framing or de/encoding.

See also: ReaderStream and ReaderStream.

Aliased Type§

pub struct BytesFramed<R, W> { /* private fields */ }

Implementations§

Source§

impl BytesFramed<(), ()>

Source

pub fn new_bytes() -> Self

Creates a new BytesFramed that bridges AsyncRead/AsyncWrite with Bytes.

See also: ReaderStream and StreamReader.