Skip to main content

ClearDirtySystem Class Template

Generic ECS system that resets dirty state for configured component types. More...

Declaration

template <typename TMemberHandle, typename ... TComponentSpecs> class helios::engine::core::systems::ClearDirtySystem<TMemberHandle, TComponentSpecs> { ... }

Public Member Typedefs Index

template <typename TMemberHandle, typename ... TComponentSpecs>
usingEngineRoleTag = SystemRole

Runtime role tag used for system registration. More...

Public Member Functions Index

template <typename TMemberHandle, typename ... TComponentSpecs>
voidupdate (UpdateContext &updateContext) noexcept

Executes one dirty-clear pass for all configured component specifications. More...

Private Member Functions Index

template <typename TComponentSpec>
voidclearDirtyFor (UpdateContext &updateContext)

Clears the dirty flag for one configured component specification. More...

Description

Generic ECS system that resets dirty state for configured component types.

Template Parameters
TMemberHandle

Member/registry handle type used to access ECS components.

TComponentSpecs

Component type specifications resolved via TComponentSpec::type<TMemberHandle>.

For each configured component type, the system iterates all entities with Active<TMemberHandle> enabled and calls clearDirty() on the component instance.

Definition at line 34 of file ClearDirtySystem.ixx.

Public Member Typedefs

EngineRoleTag

template <typename TMemberHandle, typename ... TComponentSpecs>
using helios::engine::core::systems::ClearDirtySystem< TMemberHandle, TComponentSpecs >::EngineRoleTag = SystemRole

Runtime role tag used for system registration.

Definition at line 62 of file ClearDirtySystem.ixx.

Public Member Functions

update()

template <typename TMemberHandle, typename ... TComponentSpecs>
void helios::engine::core::systems::ClearDirtySystem< TMemberHandle, TComponentSpecs >::update (UpdateContext & updateContext)
inline noexcept

Executes one dirty-clear pass for all configured component specifications.

Parameters
updateContext

Frame-local update context with ECS access.

Definition at line 69 of file ClearDirtySystem.ixx.

Reference helios::engine::core::registerComponents.

Private Member Functions

clearDirtyFor()

template <typename TComponentSpec>
void helios::engine::core::systems::ClearDirtySystem< TMemberHandle, TComponentSpecs >::clearDirtyFor (UpdateContext & updateContext)
inline

Clears the dirty flag for one configured component specification.

Template Parameters
TComponentSpec

Component specification type.

Parameters
updateContext

Frame-local update context providing ECS view access.

Definition at line 43 of file ClearDirtySystem.ixx.

43 void clearDirtyFor(UpdateContext& updateContext) {
44
45 using Component = typename TComponentSpec::template type<TMemberHandle>;
46
47 for (auto [entity, cmp, active] : updateContext.view<
51 cmp->clearDirty();
52 }
53 }

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


Generated via doxygen2docusaurus 2.0.0 by Doxygen 1.9.8.