Trait ByteArrayViewMut

Source
pub trait ByteArrayViewMut<'transient, 'lifespan>: ByteArrayView<'transient, 'lifespan>
where 'lifespan: 'transient,
{ // Required methods fn unit_mut(&mut self) -> &mut Unit; fn view_mut( &'transient mut self, ) -> Result<&'transient mut Vec<u8>, ArrayRetrievalError>; // Provided methods fn coerce_from_mut<T>( buffer: &mut [u8], ) -> Result<&'transient mut [T], ArrayRetrievalError> where T: Clone { ... } fn coerce_mut<T>( &'lifespan mut self, ) -> Result<&'transient mut [T], ArrayRetrievalError> where T: Clone { ... } }

Required Methods§

Source

fn unit_mut(&mut self) -> &mut Unit

Specify the unit of the data array

Source

fn view_mut( &'transient mut self, ) -> Result<&'transient mut Vec<u8>, ArrayRetrievalError>

Get a mutable view of the bytes backing this data array.

This is in turn used by ByteArrayViewMut::coerce_mut to produce a typed array

Provided Methods§

Source

fn coerce_from_mut<T>( buffer: &mut [u8], ) -> Result<&'transient mut [T], ArrayRetrievalError>
where T: Clone,

Source

fn coerce_mut<T>( &'lifespan mut self, ) -> Result<&'transient mut [T], ArrayRetrievalError>
where T: Clone,

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§

Source§

impl<'transient, 'lifespan> ByteArrayViewMut<'transient, 'lifespan> for DataArray
where 'lifespan: 'transient,