CeresEngine 0.2.0
A game development framework
Loading...
Searching...
No Matches
CeresEngine::AbstractSystem Class Referenceabstract

A abstract class that provides a trait that allows checking for system implementations. More...

#include <CeresEngine/Entity/System.hpp>

Inheritance diagram for CeresEngine::AbstractSystem:
CeresEngine::System< T, EntityObjectSet< EOs... >, ComponentSet< Cs... >, EntityActionSet< As... > >

Public Member Functions

virtual ~AbstractSystem ()=default
 Defaulted virtual destructor.
 
virtual void update (double time)=0
 Updates the system.
 
virtual SystemOrder getOrder () const noexcept
 

Static Public Attributes

static const SystemOrder defaultOrder
 The default execution updating order for systems.
 

Protected Member Functions

virtual void attached (EntityManager &entityManager, SystemManager &systemManager)
 A method called by the system manager once the system has been attached to the manager.
 
virtual void detached (EntityManager &entityManager, SystemManager &systemManager)
 A method called by the system manager once the system has been detached from the manager.
 
EntityManagerentities () noexcept
 
const EntityManagerentities () const noexcept
 
SystemManagersystems () noexcept
 
const SystemManagersystems () const noexcept
 
EntityEventManagerevents () noexcept
 
const EntityEventManagerevents () const noexcept
 

Private Attributes

EntityManagermEntityManager = nullptr
 The entity manager for the system.
 
SystemManagermSystemManager = nullptr
 The system manager for the system.
 

Static Private Attributes

static SystemID nextSystemID = 0
 The next system ID to be statically allocated by the compiler.
 

Friends

class SystemManager
 
template<typename T , typename EntityObjects , typename Components , typename Actions >
class System
 

Detailed Description

A abstract class that provides a trait that allows checking for system implementations.

Constructor & Destructor Documentation

◆ ~AbstractSystem()

virtual CeresEngine::AbstractSystem::~AbstractSystem ( )
virtualdefault

Defaulted virtual destructor.

Member Function Documentation

◆ attached()

virtual void CeresEngine::AbstractSystem::attached ( EntityManager entityManager,
SystemManager systemManager 
)
protectedvirtual

A method called by the system manager once the system has been attached to the manager.

Parameters
entityManagerThe entity manager the system is attaching
systemManagerThe system manager the system is attaching

Reimplemented in CeresEngine::System< T, EntityObjectSet< EOs... >, ComponentSet< Cs... >, EntityActionSet< As... > >.

◆ detached()

virtual void CeresEngine::AbstractSystem::detached ( EntityManager entityManager,
SystemManager systemManager 
)
protectedvirtual

A method called by the system manager once the system has been detached from the manager.

Parameters
entityManagerThe entity manager the system is attaching
systemManagerThe system manager the system is attaching

Reimplemented in CeresEngine::System< T, EntityObjectSet< EOs... >, ComponentSet< Cs... >, EntityActionSet< As... > >.

◆ entities() [1/2]

const EntityManager & CeresEngine::AbstractSystem::entities ( ) const
protectednoexcept
Returns
The entity manager

◆ entities() [2/2]

EntityManager & CeresEngine::AbstractSystem::entities ( )
protectednoexcept
Returns
The entity manager

◆ events() [1/2]

const EntityEventManager & CeresEngine::AbstractSystem::events ( ) const
protectednoexcept
Returns
The event manager

◆ events() [2/2]

EntityEventManager & CeresEngine::AbstractSystem::events ( )
protectednoexcept
Returns
The event manager

◆ getOrder()

virtual SystemOrder CeresEngine::AbstractSystem::getOrder ( ) const
virtualnoexcept
Returns
The order in which the system should be updated.

◆ systems() [1/2]

const SystemManager & CeresEngine::AbstractSystem::systems ( ) const
protectednoexcept
Returns
The system manager

◆ systems() [2/2]

SystemManager & CeresEngine::AbstractSystem::systems ( )
protectednoexcept
Returns
The system manager

◆ update()

virtual void CeresEngine::AbstractSystem::update ( double  time)
pure virtual

Updates the system.

Parameters
timeThe amount of time elapsed since the last update

Friends And Related Symbol Documentation

◆ System

◆ SystemManager

Member Data Documentation

◆ defaultOrder

const SystemOrder CeresEngine::AbstractSystem::defaultOrder
static

The default execution updating order for systems.

◆ mEntityManager

EntityManager* CeresEngine::AbstractSystem::mEntityManager = nullptr
private

The entity manager for the system.

◆ mSystemManager

SystemManager* CeresEngine::AbstractSystem::mSystemManager = nullptr
private

The system manager for the system.

◆ nextSystemID

SystemID CeresEngine::AbstractSystem::nextSystemID = 0
inlinestaticprivate

The next system ID to be statically allocated by the compiler.


The documentation for this class was generated from the following file: