Trait rin::ecs::storage::Storage[][src]

pub trait Storage<'a, T> {
    type Get;
    type GetMut;
    type DerefTarget: ?Sized;
    type IdedIter: Iterator;
    type Iter: Iterator;
    type IterMut: Iterator;
Show methods pub fn new() -> Self;
pub fn with_capacity(capacity: usize) -> Self;
pub fn insert(&mut self, guid: usize, t: T);
pub fn remove(&mut self, guid: usize);
pub unsafe fn get(&self, guid: usize) -> Self::Get;
pub unsafe fn get_mut(&mut self, guid: usize) -> Self::GetMut;
pub unsafe fn fast_get(&self, idx: usize) -> Self::Get;
pub unsafe fn fast_get_mut(&mut self, idx: usize) -> Self::GetMut;
pub fn fast_index(&self, guid: usize) -> usize;
pub fn guid_from_fast_index(&self, guid: usize) -> usize;
pub fn contains(&self, guid: usize) -> bool;
pub fn ided_iter(&self) -> Self::IdedIter;
pub fn iter(&self) -> Self::Iter;
pub fn iter_mut(&mut self) -> Self::IterMut; pub fn update(&mut self) { ... }
pub fn tracks_changes() -> bool { ... }
pub fn storage_changed(&self) -> bool { ... }
}

Associated Types

type Get[src]

type GetMut[src]

type DerefTarget: ?Sized[src]

type IdedIter: Iterator[src]

type Iter: Iterator[src]

type IterMut: Iterator[src]

Loading content...

Required methods

pub fn new() -> Self[src]

pub fn with_capacity(capacity: usize) -> Self[src]

pub fn insert(&mut self, guid: usize, t: T)[src]

pub fn remove(&mut self, guid: usize)[src]

pub unsafe fn get(&self, guid: usize) -> Self::Get[src]

pub unsafe fn get_mut(&mut self, guid: usize) -> Self::GetMut[src]

pub unsafe fn fast_get(&self, idx: usize) -> Self::Get[src]

pub unsafe fn fast_get_mut(&mut self, idx: usize) -> Self::GetMut[src]

pub fn fast_index(&self, guid: usize) -> usize[src]

pub fn guid_from_fast_index(&self, guid: usize) -> usize[src]

pub fn contains(&self, guid: usize) -> bool[src]

pub fn ided_iter(&self) -> Self::IdedIter[src]

pub fn iter(&self) -> Self::Iter[src]

pub fn iter_mut(&mut self) -> Self::IterMut[src]

Loading content...

Provided methods

pub fn update(&mut self)[src]

pub fn tracks_changes() -> bool[src]

pub fn storage_changed(&self) -> bool[src]

Loading content...

Implementations on Foreign Types

impl<'a, T> Storage<'a, T> for KeyedDenseVec<usize, T> where
    T: 'a, 
[src]

type Get = &'a T

type GetMut = &'a mut T

type DerefTarget = T

type IdedIter = Iter<'a, usize, T>

type Iter = Values<'a, T>

type IterMut = ValuesMut<'a, T>

Loading content...

Implementors

impl<'a, T> Storage<'a, T> for Forest<T> where
    T: 'a, 
[src]

type Get = &'a T

type GetMut = &'a mut T

type DerefTarget = T

type IdedIter = AllIdedData<'a, T>

type Iter = AllData<'a, T>

type IterMut = AllDataMut<'a, T>

impl<'a, T> Storage<'a, T> for OneToNForest<T> where
    T: 'a + Component
[src]

type Get = RootsIter<'a, T>

type GetMut = RootsIterMut<'a, T>

type DerefTarget = RootsIter<'a, T>

type IdedIter = RawIdedIter<'a, T>

type Iter = RawIter<'a, T>

type IterMut = RawIterMut<'a, T>

impl<'a, T> Storage<'a, T> for UniqueDenseVec<T> where
    T: 'a + Hash
[src]

type Get = &'a T

type GetMut = RefMut<'a, T>

type DerefTarget = T

type IdedIter = Iter<'a, usize, T>

type Iter = Values<'a, T>

type IterMut = UniqueIterMut<'a, T>

impl<'a, T> Storage<'a, T> for VecStorage<T> where
    T: 'a, 
[src]

type Get = &'a T

type GetMut = &'a mut T

type DerefTarget = T

type IdedIter = RawIdedIter<'a, T>

type Iter = RawIter<'a, T>

type IterMut = RawIterMut<'a, T>

impl<'a, T, G> Storage<'a, T> for _DenseOneToNVec<T, G> where
    T: 'a,
    G: 'a + GroupExt
[src]

type Get = SliceView<'a, T>

type GetMut = SliceViewMut<'a, T>

type DerefTarget = [T]

type IdedIter = IdedIter<'a, T, G>

type Iter = Iter<'a, T, G>

type IterMut = IterMut<'a, T, G>

impl<'a, T, S> Storage<'a, T> for AutoChanged<S, T> where
    T: 'a + Component,
    S: Storage<'a, T>,
    <S as Storage<'a, T>>::GetMut: Changes
[src]

type Get = <S as Storage<'a, T>>::Get

type GetMut = <S as Storage<'a, T>>::GetMut

type DerefTarget = <S as Storage<'a, T>>::DerefTarget

type IdedIter = <S as Storage<'a, T>>::IdedIter

type Iter = <S as Storage<'a, T>>::Iter

type IterMut = <S as Storage<'a, T>>::IterMut

impl<'a, T, S> Storage<'a, T> for Changed<S, T> where
    T: 'a,
    S: Storage<'a, T>, 
[src]

type Get = <S as Storage<'a, T>>::Get

type GetMut = <S as Storage<'a, T>>::GetMut

type DerefTarget = <S as Storage<'a, T>>::DerefTarget

type IdedIter = <S as Storage<'a, T>>::IdedIter

type Iter = <S as Storage<'a, T>>::Iter

type IterMut = <S as Storage<'a, T>>::IterMut

Loading content...