Raven Engine v0.1
A modern 3D Game Engine
Loading...
Searching...
No Matches
Raven::TypeData Struct Reference

Metadata about a type. More...

#include <TypeData.h>

Static Public Member Functions

template<typename T>
static constexpr TypeData Create ()
 Generate TypeData metadata for a given type.

Public Attributes

std::string_view Name {}
 The name of the type.
u32 Size {}
 The size of the type in bytes.
u32 Align {}
 The alignment of the type in bytes.
std::vector< VariableDataMemberVars {}
 List of all Member variables.

Detailed Description

Metadata about a type.

Stores essential information about a type, such as its name, size, and alignment. This structure helps in the engine's type reflection system and is used to associate metadata with the unique TypeIDs for various types.

Member Function Documentation

◆ Create()

template<typename T>
constexpr TypeData Raven::TypeData::Create ( )
inlinestaticconstexpr

Generate TypeData metadata for a given type.

In addition to populating basic metadata (name, size, alignment), this function triggers recursive registration of any contained or dependent types via ContainedTypeRegistrar<T>.

This function has side effects and may cause additional types to be registered in the global TypeRegistry.

Template Parameters
TThe type to generate the TypeData for.
Returns
A TypeData structure containing metadata for the type T.
Note
This function is not a pure factory and should not be treated as such.

Member Data Documentation

◆ Align

u32 Raven::TypeData::Align {}

The alignment of the type in bytes.

◆ MemberVars

std::vector<VariableData> Raven::TypeData::MemberVars {}

List of all Member variables.

◆ Name

std::string_view Raven::TypeData::Name {}

The name of the type.

◆ Size

u32 Raven::TypeData::Size {}

The size of the type in bytes.


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