Struct calx_ecs::ComponentData [] [src]

pub struct ComponentData<C> { /* fields omitted */ }

Storage for a single component type.

Methods

impl<C> ComponentData<C>
[src]

Construct new empty ComponentData instance.

Insert a component to an entity.

Return whether an entity contains this component.

Get a reference to a component only if it exists for this entity.

Get a mutable reference to a component only if it exists for this entity.

Iterate entity-component pairs for this component.

Iterate mutable entity-component pairs for this component.

Trait Implementations

impl<C> Index<Entity> for ComponentData<C>
[src]

The returned type after indexing

The method for the indexing (container[index]) operation

impl<C> IndexMut<Entity> for ComponentData<C>
[src]

The method for the mutable indexing (container[index]) operation

impl<C> AnyComponent for ComponentData<C>
[src]

Remove an entity's component.