pub struct SharedArgs<'a> { /* private fields */ }Expand description
Shared arguments for zero-copy access
Implementations§
Sourcepub fn read_str_at(&self, offset: usize, len: usize) -> Result<&str, DCPError>
pub fn read_str_at(&self, offset: usize, len: usize) -> Result<&str, DCPError>
Read a string at the given offset with bounds checking
Sourcepub fn read_i32_at(&self, offset: usize) -> Result<i32, DCPError>
pub fn read_i32_at(&self, offset: usize) -> Result<i32, DCPError>
Read an i32 at the given offset with bounds checking
Sourcepub fn read_i64_at(&self, offset: usize) -> Result<i64, DCPError>
pub fn read_i64_at(&self, offset: usize) -> Result<i64, DCPError>
Read an i64 at the given offset with bounds checking
Sourcepub fn read_u32_at(&self, offset: usize) -> Result<u32, DCPError>
pub fn read_u32_at(&self, offset: usize) -> Result<u32, DCPError>
Read a u32 at the given offset with bounds checking
Sourcepub fn read_bytes_at(
&self,
offset: usize,
len: usize,
) -> Result<&[u8], DCPError>
pub fn read_bytes_at( &self, offset: usize, len: usize, ) -> Result<&[u8], DCPError>
Read bytes at the given offset with bounds checking
Auto Trait Implementations§
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