mirror of
https://github.com/tokio-rs/bytes.git
synced 2026-08-11 00:00:23 +02:00
40 lines
762 B
Rust
40 lines
762 B
Rust
#![crate_name = "bytes"]
|
|
#![deny(warnings)]
|
|
|
|
#[macro_use]
|
|
extern crate log;
|
|
extern crate byteorder;
|
|
|
|
// Implementation in here
|
|
mod imp;
|
|
|
|
pub mod alloc;
|
|
|
|
pub use imp::buf::{Buf, MutBuf};
|
|
pub use imp::bytes::Bytes;
|
|
|
|
pub mod buf {
|
|
//! Traits, helpers, and type definitions for working with buffers.
|
|
|
|
pub use imp::buf::{
|
|
Source,
|
|
Sink,
|
|
Reader,
|
|
ReadExt,
|
|
Writer,
|
|
WriteExt,
|
|
Fmt,
|
|
};
|
|
pub use imp::buf::append::AppendBuf;
|
|
pub use imp::buf::block::{BlockBuf, BlockBufCursor};
|
|
pub use imp::buf::byte::{ByteBuf, MutByteBuf};
|
|
pub use imp::buf::ring::RingBuf;
|
|
pub use imp::buf::take::Take;
|
|
|
|
pub use imp::bytes::BytesBuf;
|
|
}
|
|
|
|
use std::u32;
|
|
|
|
const MAX_CAPACITY: usize = u32::MAX as usize;
|