Symphony Of Empires
|
An entity which can only be referenced by an (presumably) unique Id this is the base class for the other entity types. More...
#include <entity.hpp>
Public Types | |
using | Id = T |
Public Member Functions | |
constexpr | Entity () noexcept=default |
constexpr | Entity (Entity &&) noexcept=default |
constexpr | Entity (const Entity &) noexcept=default |
constexpr Entity & | operator= (const Entity &) noexcept=default |
constexpr | ~Entity () noexcept=default |
constexpr bool | is_invalid () const |
Checks if the current id is invalid. More... | |
constexpr bool | is_valid () const |
Checks if the current id is valid. More... | |
constexpr | operator Id () const noexcept |
constexpr | operator size_t () const noexcept |
constexpr Id | get_id () const |
Static Public Member Functions | |
constexpr static Id | invalid () |
Returns an invalid id. More... | |
constexpr static bool | is_invalid (Id id) |
Checks if the id is not valid. More... | |
constexpr static bool | is_valid (Id id) |
Checks if the id is valid. More... | |
Public Attributes | |
Id | cached_id |
Id used to speed up Id lookups on any context. More... | |
An entity which can only be referenced by an (presumably) unique Id this is the base class for the other entity types.
T | The type used for the Id |
Definition at line 94 of file entity.hpp.
Definition at line 95 of file entity.hpp.
|
constexprdefaultnoexcept |
Returns an invalid id.
Definition at line 110 of file entity.hpp.
|
inlineconstexpr |
Checks if the current id is invalid.
Definition at line 133 of file entity.hpp.
Checks if the id is not valid.
id | Id to check |
Definition at line 118 of file entity.hpp.
|
inlineconstexpr |
Checks if the current id is valid.
Definition at line 140 of file entity.hpp.
Checks if the id is valid.
id | Id to check |
Definition at line 126 of file entity.hpp.
Definition at line 144 of file entity.hpp.
|
inlineconstexprnoexcept |
Definition at line 148 of file entity.hpp.
|
constexprdefaultnoexcept |
Id used to speed up Id lookups on any context.
Definition at line 106 of file entity.hpp.