docs: improve discoverability of codec module (#2523)

This commit is contained in:
Geoff Shannon
2020-05-14 16:51:55 +02:00
committed by GitHub
parent 02661ba30a
commit b44ab27359
10 changed files with 67 additions and 30 deletions
+9 -4
View File
@@ -1,8 +1,13 @@
//! Utilities for encoding and decoding frames.
//! Adaptors from AsyncRead/AsyncWrite to Stream/Sink
//!
//! Contains adapters to go from streams of bytes, [`AsyncRead`] and
//! [`AsyncWrite`], to framed streams implementing [`Sink`] and [`Stream`].
//! Framed streams are also known as transports.
//! Raw I/O objects work with byte sequences, but higher-level code
//! usually wants to batch these into meaningful chunks, called
//! "frames".
//!
//! This module contains adapters to go from streams of bytes,
//! [`AsyncRead`] and [`AsyncWrite`], to framed streams implementing
//! [`Sink`] and [`Stream`]. Framed streams are also known as
//! transports.
//!
//! [`AsyncRead`]: tokio::io::AsyncRead
//! [`AsyncWrite`]: tokio::io::AsyncWrite