pub struct Cursor<'a> { /* private fields */ }Implementations§
Source§impl<'a> Cursor<'a>
impl<'a> Cursor<'a>
pub fn new(inner: &'a mut BytesMut) -> Self
pub fn into_inner(&mut self) -> BytesMut
pub const fn position(&self) -> usize
pub fn set_position(&mut self, pos: usize)
pub fn reset(&mut self)
pub fn len(&self) -> usize
pub fn remaining(&self) -> &[u8] ⓘ
pub fn split_at_current_pos(&mut self) -> BytesMut
Trait Implementations§
Auto Trait Implementations§
impl<'a> Freeze for Cursor<'a>
impl<'a> RefUnwindSafe for Cursor<'a>
impl<'a> Send for Cursor<'a>
impl<'a> Sync for Cursor<'a>
impl<'a> Unpin for Cursor<'a>
impl<'a> !UnwindSafe for Cursor<'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