Skip to main content

HasTag.ixx File

Concept for detecting a compile-time engine role tag on a type. More...

Included Headers

#include <concepts>

Namespaces Index

namespacehelios
namespaceengine

Main engine module aggregating core infrastructure and game systems. More...

namespacecommon

Shared type definitions, concepts, and tags used across engine subsystems. More...

namespaceconcepts

Compile-time concepts for engine role classification and capability detection. More...

Description

Concept for detecting a compile-time engine role tag on a type.

File Listing

The file content with the documentation metadata removed is:

1/**
2 * @file HasTag.ixx
3 * @brief Concept for detecting a compile-time engine role tag on a type.
4 */
5module;
6
7#include <concepts>
8
9export module helios.engine.common.concepts.HasTag;
10
12
13 /**
14 * @brief Detects whether T declares a nested `EngineRoleTag` alias equal to Tag.
15 *
16 * @details Used by role-specific concepts (IsManagerLike, IsSystemLike) to verify
17 * that a type has been explicitly tagged for a particular engine role.
18 * The tag must be declared as `using EngineRoleTag = Tag;` inside the class.
19 *
20 * @tparam T The type to inspect.
21 * @tparam Tag The expected tag type (e.g. ManagerRole, SystemRole).
22 *
23 * @see ManagerRole
24 * @see SystemRole
25 */
26 template<class T, class Tag>
27 concept HasTag = requires { typename T::EngineRoleTag; } &&
28 std::same_as<typename T::EngineRoleTag, Tag>;
29
30}

Generated via doxygen2docusaurus 2.0.0 by Doxygen 1.15.0.