Enum orx_split_vec::prelude::SplitVecSlice
source · pub enum SplitVecSlice<'a, T> {
Ok(&'a [T]),
Fragmented(usize, usize),
OutOfBounds,
}
Expand description
Returns the result of trying to get a slice as a contagious memory from the split vector.
Variants§
Ok(&'a [T])
The desired range completely belongs to one fragment and the slice can be provided.
Fragmented(usize, usize)
The desired range is split to at least two fragments. The tuple contains indices of the fragments containing the first and last element of the desired range.
OutOfBounds
An error case where the desired range is out of bounds of the vector.
Trait Implementations§
source§impl<'a, T: Clone> Clone for SplitVecSlice<'a, T>
impl<'a, T: Clone> Clone for SplitVecSlice<'a, T>
source§fn clone(&self) -> SplitVecSlice<'a, T>
fn clone(&self) -> SplitVecSlice<'a, T>
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl<'a, T: Debug> Debug for SplitVecSlice<'a, T>
impl<'a, T: Debug> Debug for SplitVecSlice<'a, T>
source§impl<'a, T: PartialEq> PartialEq for SplitVecSlice<'a, T>
impl<'a, T: PartialEq> PartialEq for SplitVecSlice<'a, T>
impl<'a, T: Eq> Eq for SplitVecSlice<'a, T>
impl<'a, T> StructuralPartialEq for SplitVecSlice<'a, T>
Auto Trait Implementations§
impl<'a, T> Freeze for SplitVecSlice<'a, T>
impl<'a, T> RefUnwindSafe for SplitVecSlice<'a, T>where
T: RefUnwindSafe,
impl<'a, T> Send for SplitVecSlice<'a, T>where
T: Sync,
impl<'a, T> Sync for SplitVecSlice<'a, T>where
T: Sync,
impl<'a, T> Unpin for SplitVecSlice<'a, T>
impl<'a, T> UnwindSafe for SplitVecSlice<'a, T>where
T: RefUnwindSafe,
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
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)