30 virtual std::string
getId()
const = 0;
36 virtual const std::map<CompType,
37 std::vector<std::shared_ptr<IComponent>>> &
49 virtual const std::vector<std::shared_ptr<IComponent>> &
65 std::shared_ptr<IComponent> component) = 0;
Definition: ArcadeStruct.hpp:10
Definition: IComponent.hpp:39
The IEntity interface.
Definition: IEntity.hpp:22
virtual std::string getId() const =0
Get the entity id.
virtual ~IEntity()=default
virtual void addComponent(std::shared_ptr< IComponent > component)=0
Add a component.
virtual void removeComponent(const std::string &id)=0
Remove a component.
virtual IComponent & getComponents(const std::string &id)=0
Get component by its id.
virtual const std::vector< std::shared_ptr< IComponent > > & getComponents(CompType type) const =0
Get all components of type compType
virtual const std::map< CompType, std::vector< std::shared_ptr< IComponent > > > & getComponents() const =0
Get all components.
virtual void removeComponent(CompType type)=0
Remove all components of type CompType