Struct rustix::io::IoSliceRaw
source · #[repr(transparent)]pub struct IoSliceRaw<'a> { /* private fields */ }
Expand description
A buffer type used with vmsplice
.
It is guaranteed to be ABI compatible with the iovec type on Unix platforms
and WSABUF
on Windows. Unlike IoSlice
and IoSliceMut
it is
semantically like a raw pointer, and therefore can be shared or mutated as
needed.
Implementations§
source§impl<'a> IoSliceRaw<'a>
impl<'a> IoSliceRaw<'a>
sourcepub fn from_slice(buf: &'a [u8]) -> Self
pub fn from_slice(buf: &'a [u8]) -> Self
Creates a new IoSlice
wrapping a byte slice.
sourcepub fn from_slice_mut(buf: &'a mut [u8]) -> Self
pub fn from_slice_mut(buf: &'a mut [u8]) -> Self
Creates a new IoSlice
wrapping a mutable byte slice.