Trait microui::IVec

source ·
pub trait IVec<T: Default + Copy> {
Show 13 methods // Required methods fn push(&mut self, t: T) -> (&mut T, usize); fn pop(&mut self); fn top(&self) -> Option<&T>; fn top_mut(&mut self) -> Option<&mut T>; fn capacity(&self) -> usize; fn len(&self) -> usize; fn clear(&mut self); fn as_slice(&self) -> &[T]; fn as_slice_mut(&mut self) -> &mut [T]; fn get(&self, index: usize) -> &T; fn get_mut(&mut self, index: usize) -> &mut T; fn reverse(&mut self); // Provided method fn append(&mut self, other: &[T]) { ... }
}

Required Methods§

source

fn push(&mut self, t: T) -> (&mut T, usize)

source

fn pop(&mut self)

source

fn top(&self) -> Option<&T>

source

fn top_mut(&mut self) -> Option<&mut T>

source

fn capacity(&self) -> usize

source

fn len(&self) -> usize

source

fn clear(&mut self)

source

fn as_slice(&self) -> &[T]

source

fn as_slice_mut(&mut self) -> &mut [T]

source

fn get(&self, index: usize) -> &T

source

fn get_mut(&mut self, index: usize) -> &mut T

source

fn reverse(&mut self)

Provided Methods§

source

fn append(&mut self, other: &[T])

Trait Implementations§

source§

impl<T: Default + Copy> Index<usize> for dyn IVec<T>

§

type Output = T

The returned type after indexing.
source§

fn index(&self, index: usize) -> &Self::Output

Performs the indexing (container[index]) operation. Read more
source§

impl<T: Default + Copy> IndexMut<usize> for dyn IVec<T>

source§

fn index_mut(&mut self, index: usize) -> &mut Self::Output

Performs the mutable indexing (container[index]) operation. Read more

Implementors§

source§

impl<T: Default + Copy, const N: usize> IVec<T> for FixedVec<T, N>