Helios Engine
A modular ECS based data-oriented C++23 game engine framework
Loading...
Searching...
No Matches

Id for systems. More...

#include <system.hpp>

Public Member Functions

constexpr std::strong_ordering operator<=> (const SystemId &) const noexcept=default

Static Public Member Functions

static constexpr SystemId From (std::string_view name) noexcept
 Creates system id from a name.
static constexpr SystemId From (SystemTypeIndex index) noexcept
 Creates system id from a system type index.
static constexpr SystemId From (SystemTypeId id) noexcept
 Creates system id from a system type id.
template<SystemTrait T>
static constexpr SystemId From () noexcept
 Creates system id from a system type.
template<SystemTrait T>
static constexpr SystemId From (const T &) noexcept
 Creates system id from a system type.

Public Attributes

size_t id = 0

Detailed Description

Id for systems.

Definition at line 146 of file system.hpp.

Member Function Documentation

◆ From() [1/5]

template<SystemTrait T>
constexpr SystemId helios::ecs::SystemId::From ( )
inlinestaticnodiscardconstexprnoexcept

Creates system id from a system type.

Template Parameters
TSystem type
Returns
System id

Definition at line 182 of file system.hpp.

◆ From() [2/5]

template<SystemTrait T>
constexpr SystemId helios::ecs::SystemId::From ( const T & )
inlinestaticnodiscardconstexprnoexcept

Creates system id from a system type.

Template Parameters
TSystem type
Parameters
instanceSystem instance
Returns
System id

Definition at line 193 of file system.hpp.

◆ From() [3/5]

constexpr SystemId helios::ecs::SystemId::From ( std::string_view name)
inlinestaticnodiscardconstexprnoexcept

Creates system id from a name.

Parameters
nameSystem name
Returns
System id

Definition at line 154 of file system.hpp.

◆ From() [4/5]

constexpr SystemId helios::ecs::SystemId::From ( SystemTypeId id)
inlinestaticnodiscardconstexprnoexcept

Creates system id from a system type id.

Parameters
idSystem type id
Returns
System id

Definition at line 172 of file system.hpp.

◆ From() [5/5]

constexpr SystemId helios::ecs::SystemId::From ( SystemTypeIndex index)
inlinestaticnodiscardconstexprnoexcept

Creates system id from a system type index.

Parameters
indexSystem type index
Returns
System id

Definition at line 163 of file system.hpp.

◆ operator<=>()

std::strong_ordering helios::ecs::SystemId::operator<=> ( const SystemId & ) const
constexprdefaultnoexcept

Member Data Documentation

◆ id

size_t helios::ecs::SystemId::id = 0

Definition at line 147 of file system.hpp.