Struct variable_len_reader::util::bufs::ReadBuf
source · pub struct ReadBuf<'a> { /* private fields */ }
Implementations§
source§impl<'a> ReadBuf<'a>
impl<'a> ReadBuf<'a>
pub fn new(buf: &'a mut [u8]) -> Self
pub fn advance(&mut self, cnt: usize)
pub fn buf(&self) -> &[u8] ⓘ
pub fn buf_mut(&mut self) -> &mut [u8] ⓘ
pub fn filled(&self) -> usize
pub fn left(&self) -> usize
pub fn clear(&mut self)
pub fn set_filled(&mut self, filled: usize)
pub fn set(&mut self, val: u8)
pub fn put(&mut self, val: u8)
pub fn set_slice(&mut self, slice: &[u8])
pub fn put_slice(&mut self, slice: &[u8])
Trait Implementations§
source§impl<'a> From<&'a mut OwnedReadBuf128> for ReadBuf<'a>
impl<'a> From<&'a mut OwnedReadBuf128> for ReadBuf<'a>
source§fn from(value: &'a mut OwnedReadBuf128) -> Self
fn from(value: &'a mut OwnedReadBuf128) -> Self
Converts to this type from the input type.
source§impl<'a> From<&'a mut OwnedReadBuf16> for ReadBuf<'a>
impl<'a> From<&'a mut OwnedReadBuf16> for ReadBuf<'a>
source§fn from(value: &'a mut OwnedReadBuf16) -> Self
fn from(value: &'a mut OwnedReadBuf16) -> Self
Converts to this type from the input type.
source§impl<'a> From<&'a mut OwnedReadBuf32> for ReadBuf<'a>
impl<'a> From<&'a mut OwnedReadBuf32> for ReadBuf<'a>
source§fn from(value: &'a mut OwnedReadBuf32) -> Self
fn from(value: &'a mut OwnedReadBuf32) -> Self
Converts to this type from the input type.
source§impl<'a> From<&'a mut OwnedReadBuf64> for ReadBuf<'a>
impl<'a> From<&'a mut OwnedReadBuf64> for ReadBuf<'a>
source§fn from(value: &'a mut OwnedReadBuf64) -> Self
fn from(value: &'a mut OwnedReadBuf64) -> Self
Converts to this type from the input type.
source§impl<'a> From<&'a mut OwnedReadBuf8> for ReadBuf<'a>
impl<'a> From<&'a mut OwnedReadBuf8> for ReadBuf<'a>
source§fn from(value: &'a mut OwnedReadBuf8) -> Self
fn from(value: &'a mut OwnedReadBuf8) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl<'a> RefUnwindSafe for ReadBuf<'a>
impl<'a> Send for ReadBuf<'a>
impl<'a> Sync for ReadBuf<'a>
impl<'a> Unpin for ReadBuf<'a>
impl<'a> !UnwindSafe for ReadBuf<'a>
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