[−][src]Struct rust_3d::DynamicPrecisionIndexVec
DynamicPrecisionIndexVec is a memory efficient container with a usize interface. It uses u8 -> u16 -> u32 -> usize for storage depending on the largest index's size
Implementations
impl DynamicPrecisionIndexVec
[src]
pub fn new() -> Self
[src]
Creates a new DynamicPrecisionIndexVec with u8 precision
pub fn get_u8(&self) -> Option<&Vec<u8>>
[src]
If storage is currently done with u8 precision, returns a reference to the inner Vec
pub fn get_u8_mut(&mut self) -> Option<&mut Vec<u8>>
[src]
If storage is currently done with u8 precision, returns a mutable reference to the inner Vec
pub fn get_u16(&self) -> Option<&Vec<u16>>
[src]
If storage is currently done with u16 precision, returns a reference to the inner Vec
pub fn get_u16_mut(&mut self) -> Option<&mut Vec<u16>>
[src]
If storage is currently done with u16 precision, returns a mutable reference to the inner Vec
pub fn get_u32(&self) -> Option<&Vec<u32>>
[src]
If storage is currently done with u32 precision, returns a reference to the inner Vec
pub fn get_u32_mut(&mut self) -> Option<&mut Vec<u32>>
[src]
If storage is currently done with u32 precision, returns a mutable reference to the inner Vec
pub fn get_usize(&mut self) -> Option<&Vec<usize>>
[src]
If storage is currently done with usize precision, returns a reference to the inner Vec
pub fn get_usize_mut(&mut self) -> Option<&mut Vec<usize>>
[src]
If storage is currently done with usize precision, returns a mutable reference to the inner Vec
pub fn get_usize_upgraded(&mut self) -> &Vec<usize>
[src]
First promotes the precision to usize, then returns a reference to the Vec
pub fn get_usize_upgraded_mut(&mut self) -> &mut Vec<usize>
[src]
First promotes the precision to usize, then returns a mutable reference to the Vec
Trait Implementations
impl Clone for DynamicPrecisionIndexVec
[src]
fn clone(&self) -> DynamicPrecisionIndexVec
[src]
fn clone_from(&mut self, source: &Self)
1.0.0[src]
impl Default for DynamicPrecisionIndexVec
[src]
fn default() -> DynamicPrecisionIndexVec
[src]
impl<'_> From<&'_ Vec<u16>> for DynamicPrecisionIndexVec
[src]
impl<'_> From<&'_ Vec<u32>> for DynamicPrecisionIndexVec
[src]
impl<'_> From<&'_ Vec<u8>> for DynamicPrecisionIndexVec
[src]
impl<'_> From<&'_ Vec<usize>> for DynamicPrecisionIndexVec
[src]
impl From<Vec<u16>> for DynamicPrecisionIndexVec
[src]
impl From<Vec<u32>> for DynamicPrecisionIndexVec
[src]
impl From<Vec<u8>> for DynamicPrecisionIndexVec
[src]
impl From<Vec<usize>> for DynamicPrecisionIndexVec
[src]
impl IsIndexContainer for DynamicPrecisionIndexVec
[src]
fn ensure_supported(&mut self, x: usize)
[src]
fn get(&self, i: usize) -> usize
[src]
fn set(&mut self, i: usize, x: usize)
[src]
fn push(&mut self, x: usize)
[src]
fn len(&self) -> usize
[src]
fn reserve(&mut self, n: usize)
[src]
fn iter(&self) -> IsIndexContainerIterator<Self>ⓘImportant traits for IsIndexContainerIterator<'a, IC>
impl<'a, IC> Iterator for IsIndexContainerIterator<'a, IC> where
IC: IsIndexContainer, type Item = usize;
[src]
Important traits for IsIndexContainerIterator<'a, IC>
impl<'a, IC> Iterator for IsIndexContainerIterator<'a, IC> where
IC: IsIndexContainer, type Item = usize;
fn with_capacity(n: usize) -> Self
[src]
fn with_support_for(x: usize) -> Self
[src]
fn with_capacity_and_support_for(n: usize, x: usize) -> Self
[src]
Auto Trait Implementations
impl RefUnwindSafe for DynamicPrecisionIndexVec
impl Send for DynamicPrecisionIndexVec
impl Sync for DynamicPrecisionIndexVec
impl Unpin for DynamicPrecisionIndexVec
impl UnwindSafe for DynamicPrecisionIndexVec
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,