Skip to main content

Buffer

Trait Buffer 

Source
pub trait Buffer: Deref<Target = [u8]> + DerefMut { }
Expand description

Trait for buffer types that can hold TLS record data.

Automatically implemented for any type that implements [Deref<Target = [u8]>] + DerefMut, such as Vec<u8> (owned), &mut [u8] (borrowed), Box<[u8]>, and bytes::BytesMut.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§

Source§

impl<T: Deref<Target = [u8]> + DerefMut> Buffer for T