pub struct FileMmap { /* private fields */ }
Implementations§
source§impl FileMmap
impl FileMmap
pub fn new<P: AsRef<Path>>(path: P) -> Result<Self>
pub fn len(&self) -> u64
pub fn as_ptr(&self) -> *const u8
pub unsafe fn offset(&self, addr: isize) -> *const u8
pub unsafe fn bytes(&self, addr: isize, len: usize) -> &'static [u8] ⓘ
pub fn set_len(&mut self, len: u64) -> Result<()>
pub fn append(&mut self, bytes: &[u8]) -> Result<u64>
pub fn write(&mut self, addr: isize, bytes: &[u8]) -> Result<usize>
pub fn write_0(&mut self, addr: isize, len: usize) -> Result<usize>
Trait Implementations§
Auto Trait Implementations§
impl RefUnwindSafe for FileMmap
impl Send for FileMmap
impl Sync for FileMmap
impl Unpin for FileMmap
impl UnwindSafe for FileMmap
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