|
co_ecs 0.9.0
Cobalt ECS
|
Component set holds a set of component IDs. More...
#include <component.hpp>
Public Types | |
| using | storage_type = detail::dynamic_bitset<> |
Public Member Functions | |
| template<component T> | |
| void | insert () |
| Insert component of type T. | |
| template<component T> | |
| void | erase () |
| Erase component of type T. | |
| template<component T> | |
| auto | contains () const -> bool |
| Check if component of type T is present in the set. | |
| void | insert (component_id_t id) |
| Inserts component into the set. | |
| void | erase (component_id_t id) |
| Erases component from the set. | |
| auto | contains (component_id_t id) const -> bool |
| Check if component is present in the set. | |
| void | clear () noexcept |
| auto | operator== (const component_set &rhs) const noexcept -> bool |
| Equality operator. | |
Static Public Member Functions | |
| template<component... Args> | |
| static auto | create () -> component_set |
| Construct component set from given component types. | |
Friends | |
| class | component_set_hasher |
Component set holds a set of component IDs.
| using co_ecs::component_set::storage_type = detail::dynamic_bitset<> |
|
inlinenoexcept |
|
inline |
Check if component of type T is present in the set.
| T | Component type |
|
inline |
Check if component is present in the set.
| id | Component ID |
|
inlinestatic |
Construct component set from given component types.
| Args | Components type parameter pack |
|
inline |
Erase component of type T.
| T | Component type |
|
inline |
Erases component from the set.
| id | Component ID |
|
inline |
Insert component of type T.
| T | Component type |
|
inline |
Inserts component into the set.
| id | Component ID |
|
inlinenoexcept |
Equality operator.
| rhs | Right hand side |
|
friend |