pub struct Buf { /* private fields */ }Trait Implementations§
Source§impl IoBuf for Buf
impl IoBuf for Buf
fn as_ptr(&self) -> *const u8
fn bytes_init(&self) -> usize
fn as_bytes(&self) -> Bytes
Source§unsafe fn slice_unchecked(self, range: impl RangeBounds<usize>) -> Buf
unsafe fn slice_unchecked(self, range: impl RangeBounds<usize>) -> Buf
Slice the buffer without bounds checking. Read more
Source§unsafe fn recover_from_slice(buf: Buf) -> Self
unsafe fn recover_from_slice(buf: Buf) -> Self
Recover the original buffer from a sliced buffer. Read more
fn as_slice(&self) -> &[u8] ⓘ
fn calculate_bounds<R: RangeBounds<usize>>(&self, range: R) -> (usize, usize)
Auto Trait Implementations§
impl !Freeze for Buf
impl RefUnwindSafe for Buf
impl !Send for Buf
impl !Sync for Buf
impl Unpin for Buf
impl UnwindSafe for Buf
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more