[−][src]Struct keeshond::scene::ComponentStore
Implementations
impl<C: Component + 'static> ComponentStore<C>
[src]
pub fn get_entity(&self, entity: &Entity) -> Option<&C>
[src]
pub fn get_entity_mut(&mut self, entity: &Entity) -> Option<&mut C>
[src]
pub fn clone_from_entity(&self, entity: &Entity) -> Option<C> where
C: Clone,
[src]
C: Clone,
pub fn set_entity(&mut self, entity: &Entity, component: C) -> bool
[src]
pub fn count(&self) -> usize
[src]
pub fn contains(&self, entity: &Entity) -> bool
[src]
pub fn sort<F: FnMut(&C, &C) -> Ordering>(&mut self, compare: F)
[src]
pub fn iter(&self) -> ComponentIter<'_, C>ⓘNotable traits for ComponentIter<'a, C>
impl<'a, C: Component + 'static> Iterator for ComponentIter<'a, C> type Item = (Entity, &'a C);
[src]
Notable traits for ComponentIter<'a, C>
impl<'a, C: Component + 'static> Iterator for ComponentIter<'a, C> type Item = (Entity, &'a C);
Returns a ComponentIter that iterates through all Components in the store. Typically used in a DrawerSystem.
pub fn iter_mut(&mut self) -> ComponentIterMut<'_, C>ⓘNotable traits for ComponentIterMut<'a, C>
impl<'a, C: Component + 'static> Iterator for ComponentIterMut<'a, C> type Item = (Entity, &'a mut C);
[src]
Notable traits for ComponentIterMut<'a, C>
impl<'a, C: Component + 'static> Iterator for ComponentIterMut<'a, C> type Item = (Entity, &'a mut C);
Returns a ComponentIterMut that iterates through all Components in the store. Typically used in a ThinkerSystem.
pub fn singleton(&self) -> Option<&C>
[src]
pub fn singleton_mut(&mut self) -> &mut C where
C: Default,
[src]
C: Default,
pub fn singleton_mut_or<F: FnMut() -> C>(&mut self, func: F) -> &mut C
[src]
Trait Implementations
impl<C: Debug + Component + 'static> Debug for ComponentStore<C>
[src]
Auto Trait Implementations
impl<C> RefUnwindSafe for ComponentStore<C> where
C: RefUnwindSafe,
C: RefUnwindSafe,
impl<C> Send for ComponentStore<C> where
C: Send,
C: Send,
impl<C> Sync for ComponentStore<C> where
C: Sync,
C: Sync,
impl<C> Unpin for ComponentStore<C> where
C: Unpin,
C: Unpin,
impl<C> UnwindSafe for ComponentStore<C> where
C: UnwindSafe,
C: UnwindSafe,
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> Downcast for T where
T: Any,
[src]
T: Any,
fn into_any(self: Box<T>) -> Box<dyn Any + 'static>
[src]
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any + 'static>
[src]
fn as_any(&self) -> &(dyn Any + 'static)
[src]
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
[src]
impl<T> DowncastSync for T where
T: Send + Sync + Any,
[src]
T: Send + Sync + Any,
impl<T> Erased for T
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> Same<T> for T
[src]
type Output = T
Should always be Self
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>,