Global runtime type registry for Raven Engine. More...
#include <Type.h>
Public Types | |
| using | TypeStorage = std::unordered_map<TypeID, TypeData> |
Public Member Functions | |
| template<typename T> | |
| constexpr void | RegisterType () |
| Registers a type T with the registry if not already present. | |
| TypeData & | GetTypeData (const TypeID &id) |
| Retrieves type metadata by ID. | |
| const bool | IsTypeRegistered (const TypeID &id) const noexcept |
| Checks if a type is registered. | |
| TypeStorage & | GetStorage () noexcept |
Static Public Member Functions | |
| static TypeRegistry & | Get () |
| Singleton access to the TypeRegistry. | |
Global runtime type registry for Raven Engine.
Acts as a global runtime registry mapping TypeID values to TypeData metadata. Types are registered either explicitly or via static initialization helpers.
Registration is idempotent: registering the same type multiple times has no effect. This behavior is intentional to support registration across multiple translation units.
| using Raven::TypeRegistry::TypeStorage = std::unordered_map<TypeID, TypeData> |
|
inlinestatic |
Singleton access to the TypeRegistry.
|
inlinenoexcept |
|
inlinenoexcept |
Checks if a type is registered.
| id | The TypeID to query. |
|
inlineconstexpr |
Registers a type T with the registry if not already present.
Creates a TypeID for T and inserts corresponding TypeData into the registry. If the type has already been registered, the function returns without modifying state.
| T | The type to register. |