pub trait BufferMappedRangeInterface: CommonTraits {
// Required methods
fn len(&self) -> usize;
unsafe fn read_slice(&self) -> &[u8] ⓘ;
unsafe fn write_slice(&mut self) -> WriteOnly<'_, [u8]>;
}Available on
custom only.Required Methods§
fn len(&self) -> usize
Sourceunsafe fn read_slice(&self) -> &[u8] ⓘ
unsafe fn read_slice(&self) -> &[u8] ⓘ
§Safety
Must only be used on read, not write, mappings.
Sourceunsafe fn write_slice(&mut self) -> WriteOnly<'_, [u8]>
unsafe fn write_slice(&mut self) -> WriteOnly<'_, [u8]>
§Safety
Must only be used on write, not read, mappings.
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".