mirror of
https://github.com/tokio-rs/tokio.git
synced 2026-09-07 00:00:08 +02:00
Add tokio-buf and a BufStream trait (#611)
The `BufStream` trait provides an improved API for working with asynchronous streams of bytes compared to `Stream<Item = [u8]>`
This commit is contained in:
@@ -0,0 +1,20 @@
|
||||
#![doc(html_root_url = "https://docs.rs/tokio-buf/0.1.0")]
|
||||
#![deny(missing_docs, missing_debug_implementations)]
|
||||
#![cfg_attr(test, deny(warnings))]
|
||||
|
||||
//! Asynchronous stream of bytes.
|
||||
//!
|
||||
//! This crate contains the `BufStream` trait and a number of combinators for
|
||||
//! this trait. The trait is similar to `Stream` in the `futures` library, but
|
||||
//! instead of yielding arbitrary values, it only yields types that implement
|
||||
//! `Buf` (i.e, byte collections).
|
||||
|
||||
extern crate bytes;
|
||||
extern crate either;
|
||||
#[macro_use]
|
||||
extern crate futures;
|
||||
|
||||
pub mod buf_stream;
|
||||
|
||||
#[doc(inline)]
|
||||
pub use buf_stream::BufStream;
|
||||
Reference in New Issue
Block a user