Struct orx_fixed_vec::ConcurrentFixedVec
source · pub struct ConcurrentFixedVec<T> { /* private fields */ }
Expand description
Concurrent wrapper (orx_pinned_vec::ConcurrentPinnedVec
) for the FixedVec
.
Trait Implementations§
source§impl<T> ConcurrentPinnedVec<T> for ConcurrentFixedVec<T>
impl<T> ConcurrentPinnedVec<T> for ConcurrentFixedVec<T>
source§unsafe fn into_inner(self, len: usize) -> Self::P
unsafe fn into_inner(self, len: usize) -> Self::P
Converts back to the underlying pinned vector with the given length. Read more
source§fn capacity(&self) -> usize
fn capacity(&self) -> usize
Returns the current capacity of the vector, which is actually allocated.
source§fn max_capacity(&self) -> usize
fn max_capacity(&self) -> usize
Returns the maximum possible capacity that the vector can concurrently grow to without requiring a
&mut self
reference. Read moresource§fn grow_to(&self, new_capacity: usize) -> Result<usize, PinnedVecGrowthError>
fn grow_to(&self, new_capacity: usize) -> Result<usize, PinnedVecGrowthError>
Tries to concurrently grow the capacity of the vector to at least
new_capacity
. Returns: Read moresource§fn grow_to_and_fill_with<F>(
&self,
new_capacity: usize,
_: F,
) -> Result<usize, PinnedVecGrowthError>where
F: Fn() -> T,
fn grow_to_and_fill_with<F>(
&self,
new_capacity: usize,
_: F,
) -> Result<usize, PinnedVecGrowthError>where
F: Fn() -> T,
Tries to concurrently grow the capacity of the vector to at least
new_capacity
. Returns: Read moresource§fn slices<R: RangeBounds<usize>>(
&self,
range: R,
) -> <Self::P as PinnedVec<T>>::SliceIter<'_>
fn slices<R: RangeBounds<usize>>( &self, range: R, ) -> <Self::P as PinnedVec<T>>::SliceIter<'_>
Returns an iterator of slices to the elements extending over positions
range
of the vector.source§unsafe fn slices_mut<R: RangeBounds<usize>>(
&self,
range: R,
) -> <Self::P as PinnedVec<T>>::SliceMutIter<'_>
unsafe fn slices_mut<R: RangeBounds<usize>>( &self, range: R, ) -> <Self::P as PinnedVec<T>>::SliceMutIter<'_>
Returns an iterator of mutable slices to the elements extending over positions
range
of the vector. Read moresource§unsafe fn iter<'a>(&'a self, len: usize) -> impl Iterator<Item = &'a T> + 'awhere
T: 'a,
unsafe fn iter<'a>(&'a self, len: usize) -> impl Iterator<Item = &'a T> + 'awhere
T: 'a,
Returns an iterator over positions
0..len
of the vector. Read moresource§unsafe fn iter_mut<'a>(
&'a mut self,
len: usize,
) -> impl Iterator<Item = &'a mut T> + 'awhere
T: 'a,
unsafe fn iter_mut<'a>(
&'a mut self,
len: usize,
) -> impl Iterator<Item = &'a mut T> + 'awhere
T: 'a,
Returns a mutable iterator over positions
0..len
of the vector. Read moresource§unsafe fn set_pinned_vec_len(&mut self, len: usize)
unsafe fn set_pinned_vec_len(&mut self, len: usize)
Sets the length of the underlying pinned vector to the given
len
. Read moresource§unsafe fn get(&self, index: usize) -> Option<&T>
unsafe fn get(&self, index: usize) -> Option<&T>
Returns a reference to the element at the
index
-th position. Read moresource§unsafe fn get_mut(&mut self, index: usize) -> Option<&mut T>
unsafe fn get_mut(&mut self, index: usize) -> Option<&mut T>
Returns a reference to the element at the
index
-th position. Read moresource§unsafe fn get_ptr_mut(&self, index: usize) -> *mut T
unsafe fn get_ptr_mut(&self, index: usize) -> *mut T
Returns a mutable reference to the element at the
index
-th position. Read moresource§impl<T> Debug for ConcurrentFixedVec<T>
impl<T> Debug for ConcurrentFixedVec<T>
Auto Trait Implementations§
impl<T> Freeze for ConcurrentFixedVec<T>
impl<T> RefUnwindSafe for ConcurrentFixedVec<T>where
T: RefUnwindSafe,
impl<T> !Send for ConcurrentFixedVec<T>
impl<T> !Sync for ConcurrentFixedVec<T>
impl<T> Unpin for ConcurrentFixedVec<T>where
T: Unpin,
impl<T> UnwindSafe for ConcurrentFixedVec<T>where
T: RefUnwindSafe + UnwindSafe,
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more