pub trait IoCopyable: IoBackend {
// Required methods
unsafe fn copy_from_io(view: Self::View<'_, [u8]>, buffer: *mut u8);
unsafe fn copy_to_io(view: Self::View<'_, [u8]>, buffer: *const u8);
// Provided methods
fn copy_read<T: FromBytes>(view: Self::View<'_, T>) -> T { ... }
fn copy_write<T: IntoBytes>(view: Self::View<'_, T>, value: T) { ... }
}Expand description
Trait indicating that an I/O backend supports memory copy operations.
Required Methods§
Provided Methods§
Sourcefn copy_write<T: IntoBytes>(view: Self::View<'_, T>, value: T)
fn copy_write<T: IntoBytes>(view: Self::View<'_, T>, value: T)
Copy value to view.
Destructor of value will not be executed, consistent with zerocopy::transmute.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".