pub trait ReadVolatile {
// Required method
fn read_volatile<B: BitmapSlice>(
&mut self,
buf: &mut VolatileSlice<'_, B>,
) -> Result<usize, VolatileMemoryError>;
// Provided method
fn read_exact_volatile<B: BitmapSlice>(
&mut self,
buf: &mut VolatileSlice<'_, B>,
) -> Result<(), VolatileMemoryError> { ... }
}Expand description
Required Methods§
Sourcefn read_volatile<B: BitmapSlice>(
&mut self,
buf: &mut VolatileSlice<'_, B>,
) -> Result<usize, VolatileMemoryError>
fn read_volatile<B: BitmapSlice>( &mut self, buf: &mut VolatileSlice<'_, B>, ) -> Result<usize, VolatileMemoryError>
Tries to read some bytes into the given VolatileSlice buffer, returning how many bytes
were read.
The behavior of implementations should be identical to Read::read
Provided Methods§
Sourcefn read_exact_volatile<B: BitmapSlice>(
&mut self,
buf: &mut VolatileSlice<'_, B>,
) -> Result<(), VolatileMemoryError>
fn read_exact_volatile<B: BitmapSlice>( &mut self, buf: &mut VolatileSlice<'_, B>, ) -> Result<(), VolatileMemoryError>
Tries to fill the given VolatileSlice buffer by reading from self returning an error
if insufficient bytes could be read.
The default implementation is identical to that of Read::read_exact
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".
Implementations on Foreign Types§
Source§impl ReadVolatile for &BorrowedFd<'_>
Available on crate feature rawfd only.
impl ReadVolatile for &BorrowedFd<'_>
Available on crate feature
rawfd only.fn read_volatile<B: BitmapSlice>( &mut self, buf: &mut VolatileSlice<'_, B>, ) -> Result<usize, VolatileMemoryError>
Source§impl ReadVolatile for &File
Available on crate feature rawfd only.
impl ReadVolatile for &File
Available on crate feature
rawfd only.fn read_volatile<B: BitmapSlice>( &mut self, buf: &mut VolatileSlice<'_, B>, ) -> Result<usize, VolatileMemoryError>
Source§impl ReadVolatile for &OwnedFd
Available on crate feature rawfd only.
impl ReadVolatile for &OwnedFd
Available on crate feature
rawfd only.fn read_volatile<B: BitmapSlice>( &mut self, buf: &mut VolatileSlice<'_, B>, ) -> Result<usize, VolatileMemoryError>
Source§impl ReadVolatile for &TcpStream
Available on crate feature rawfd only.
impl ReadVolatile for &TcpStream
Available on crate feature
rawfd only.fn read_volatile<B: BitmapSlice>( &mut self, buf: &mut VolatileSlice<'_, B>, ) -> Result<usize, VolatileMemoryError>
Source§impl ReadVolatile for &UnixStream
Available on crate feature rawfd only.
impl ReadVolatile for &UnixStream
Available on crate feature
rawfd only.fn read_volatile<B: BitmapSlice>( &mut self, buf: &mut VolatileSlice<'_, B>, ) -> Result<usize, VolatileMemoryError>
Source§impl ReadVolatile for &[u8]
impl ReadVolatile for &[u8]
fn read_volatile<B: BitmapSlice>( &mut self, buf: &mut VolatileSlice<'_, B>, ) -> Result<usize, VolatileMemoryError>
fn read_exact_volatile<B: BitmapSlice>( &mut self, buf: &mut VolatileSlice<'_, B>, ) -> Result<(), VolatileMemoryError>
Source§impl ReadVolatile for &mut BorrowedFd<'_>
Available on crate feature rawfd only.
impl ReadVolatile for &mut BorrowedFd<'_>
Available on crate feature
rawfd only.fn read_volatile<B: BitmapSlice>( &mut self, buf: &mut VolatileSlice<'_, B>, ) -> Result<usize, VolatileMemoryError>
Source§impl ReadVolatile for &mut File
Available on crate feature rawfd only.
impl ReadVolatile for &mut File
Available on crate feature
rawfd only.fn read_volatile<B: BitmapSlice>( &mut self, buf: &mut VolatileSlice<'_, B>, ) -> Result<usize, VolatileMemoryError>
Source§impl ReadVolatile for &mut OwnedFd
Available on crate feature rawfd only.
impl ReadVolatile for &mut OwnedFd
Available on crate feature
rawfd only.fn read_volatile<B: BitmapSlice>( &mut self, buf: &mut VolatileSlice<'_, B>, ) -> Result<usize, VolatileMemoryError>
Source§impl ReadVolatile for &mut TcpStream
Available on crate feature rawfd only.
impl ReadVolatile for &mut TcpStream
Available on crate feature
rawfd only.fn read_volatile<B: BitmapSlice>( &mut self, buf: &mut VolatileSlice<'_, B>, ) -> Result<usize, VolatileMemoryError>
Source§impl ReadVolatile for &mut UnixStream
Available on crate feature rawfd only.
impl ReadVolatile for &mut UnixStream
Available on crate feature
rawfd only.fn read_volatile<B: BitmapSlice>( &mut self, buf: &mut VolatileSlice<'_, B>, ) -> Result<usize, VolatileMemoryError>
Source§impl ReadVolatile for BorrowedFd<'_>
Available on crate feature rawfd only.
impl ReadVolatile for BorrowedFd<'_>
Available on crate feature
rawfd only.fn read_volatile<B: BitmapSlice>( &mut self, buf: &mut VolatileSlice<'_, B>, ) -> Result<usize, VolatileMemoryError>
Source§impl ReadVolatile for File
Available on crate feature rawfd only.
impl ReadVolatile for File
Available on crate feature
rawfd only.fn read_volatile<B: BitmapSlice>( &mut self, buf: &mut VolatileSlice<'_, B>, ) -> Result<usize, VolatileMemoryError>
Source§impl ReadVolatile for OwnedFd
Available on crate feature rawfd only.
impl ReadVolatile for OwnedFd
Available on crate feature
rawfd only.fn read_volatile<B: BitmapSlice>( &mut self, buf: &mut VolatileSlice<'_, B>, ) -> Result<usize, VolatileMemoryError>
Source§impl ReadVolatile for TcpStream
Available on crate feature rawfd only.
impl ReadVolatile for TcpStream
Available on crate feature
rawfd only.fn read_volatile<B: BitmapSlice>( &mut self, buf: &mut VolatileSlice<'_, B>, ) -> Result<usize, VolatileMemoryError>
Source§impl ReadVolatile for UnixStream
Available on crate feature rawfd only.
impl ReadVolatile for UnixStream
Available on crate feature
rawfd only.