Struct slice_cell::ArrayCell
source · #[repr(transparent)]pub struct ArrayCell<T, const N: usize> { /* private fields */ }Implementations§
source§impl<T, const N: usize> ArrayCell<T, N>
impl<T, const N: usize> ArrayCell<T, N>
pub fn as_std_ref(&self) -> &Cell<[T; N]>
pub fn as_std_transposed_ref(&self) -> &[Cell<T>; N]
pub fn from_std_ref(std: &Cell<[T; N]>) -> &Self
pub fn from_std_transposed_ref(std: &[Cell<T>; N]) -> &Self
pub fn as_std_mut(&mut self) -> &mut Cell<[T; N]>
pub fn as_std_transposed_mut(&mut self) -> &mut [Cell<T>; N]
pub fn from_std_mut(std: &mut Cell<[T; N]>) -> &mut Self
pub fn from_std_transposed_mut(std: &mut [Cell<T>; N]) -> &mut Self
source§impl<T, const N: usize> ArrayCell<T, N>
impl<T, const N: usize> ArrayCell<T, N>
pub fn into_inner(self) -> [T; N]
pub fn new(inner: [T; N]) -> Self
pub fn new_boxed(inner: Box<[T; N]>) -> Box<Self>
pub fn try_new_rc(inner: Rc<[T; N]>) -> Result<Rc<Self>, Rc<[T; N]>>
pub fn try_into_inner_rc(self: Rc<Self>) -> Result<Rc<[T; N]>, Rc<Self>>
pub fn get_mut(&mut self) -> &mut [T; N]
pub fn from_mut(inner: &mut [T; N]) -> &mut Self
pub const fn len(&self) -> usize
Methods from Deref<Target = SliceCell<T>>§
pub fn as_std_ref(&self) -> &Cell<[T]>
pub fn as_std_transposed_ref(&self) -> &[Cell<T>]
pub fn as_std_mut(&mut self) -> &mut Cell<[T]>
pub fn as_std_transposed_mut(&mut self) -> &mut [Cell<T>]
pub fn into_std_rc(self: Rc<Self>) -> Rc<Cell<[T]>>
pub fn into_std_transposed_rc(self: Rc<Self>) -> Rc<[Cell<T>]>
pub fn as_ptr(&self) -> *mut T
pub fn try_into_inner_rc(self: Rc<Self>) -> Result<Rc<[T]>, Rc<Self>>
pub fn get(&self) -> *mut [T]
pub fn get_mut(&mut self) -> &mut [T] ⓘ
pub fn len(&self) -> usize
pub fn split_at(&self, mid: usize) -> (&SliceCell<T>, &SliceCell<T>)
pub fn split_at_mut(
&mut self,
mid: usize
) -> (&mut SliceCell<T>, &mut SliceCell<T>)
pub fn copy_from_slice(&self, src: &[T])where
T: Copy,
pub fn clone_from_slice(&self, src: &[T])where
T: Clone,
pub fn copy_into_slice(&self, dst: &mut [T])where
T: Copy,
pub fn copy_into_vec(&self) -> Vec<T>where
T: Copy,
pub fn replace_with_vec(&self, src: Vec<T>)
pub fn swap_with_slice(&self, val: &mut [T])
sourcepub fn try_cast_rc<const N: usize>(
self: Rc<Self>
) -> Result<Rc<ArrayCell<T, N>>, Rc<Self>>
pub fn try_cast_rc<const N: usize>(
self: Rc<Self>
) -> Result<Rc<ArrayCell<T, N>>, Rc<Self>>
Replacement for TryInto impl, since Rc is not fundamental