kvarn::prelude

Struct WriteableBytes

source
pub struct WriteableBytes { /* private fields */ }
Expand description

A writeable Bytes.

Has a special allocation method for optimized usage in Kvarn.

Implementations§

source§

impl WriteableBytes

source

pub fn new() -> WriteableBytes

Creates a new writeable buffer. Consider using Self::with_capacity() if you can estimate the capacity needed.

source

pub fn with_capacity(capacity: usize) -> WriteableBytes

Crates a new writeable buffer with a specified capacity.

source

pub fn into_inner(self) -> BytesMut<