MQEngine
载入中...
搜索中...
未找到
MQEngine::ComponentReflection类 参考

#include <ComponentReflection.h>

Public 成员函数

 ComponentReflection ()
 ~ComponentReflection ()=default
const std::unordered_map< std::string, ComponentInfo > & getComponentInfos () const
bool hasComponent (entt::registry &registry, entt::entity entity, const std::string &componentName) const
ComponentValue getComponentField (entt::registry &registry, entt::entity entity, const std::string &componentName, const std::string &fieldName) const
void setComponentField (entt::registry &registry, entt::entity entity, const std::string &componentName, const std::string &fieldName, const ComponentValue &value) const
void addComponent (entt::registry &registry, entt::entity entity, const std::string &componentName) const
void removeComponent (entt::registry &registry, entt::entity entity, const std::string &componentName) const
std::vector< std::string > getComponentFieldNames (const std::string &componentName) const
std::string getComponentFieldType (const std::string &componentName, const std::string &fieldName) const
std::vector< std::string > getRegisteredComponentNames () const

Private 成员函数

template<typename T>
void registerComponent (const std::string &name)

Private 属性

std::unordered_map< std::string, ComponentInfom_componentInfos

构造及析构函数说明

◆ ComponentReflection()

MQEngine::ComponentReflection::ComponentReflection ( )
函数调用图:

◆ ~ComponentReflection()

MQEngine::ComponentReflection::~ComponentReflection ( )
default
函数调用图:

成员函数说明

◆ addComponent()

void MQEngine::ComponentReflection::addComponent ( entt::registry & registry,
entt::entity entity,
const std::string & componentName ) const
这是这个函数的调用关系图:

◆ getComponentField()

ComponentValue MQEngine::ComponentReflection::getComponentField ( entt::registry & registry,
entt::entity entity,
const std::string & componentName,
const std::string & fieldName ) const
这是这个函数的调用关系图:

◆ getComponentFieldNames()

std::vector< std::string > MQEngine::ComponentReflection::getComponentFieldNames ( const std::string & componentName) const
这是这个函数的调用关系图:

◆ getComponentFieldType()

std::string MQEngine::ComponentReflection::getComponentFieldType ( const std::string & componentName,
const std::string & fieldName ) const
这是这个函数的调用关系图:

◆ getComponentInfos()

const std::unordered_map< std::string, ComponentInfo > & MQEngine::ComponentReflection::getComponentInfos ( ) const
这是这个函数的调用关系图:

◆ getRegisteredComponentNames()

std::vector< std::string > MQEngine::ComponentReflection::getRegisteredComponentNames ( ) const
这是这个函数的调用关系图:

◆ hasComponent()

bool MQEngine::ComponentReflection::hasComponent ( entt::registry & registry,
entt::entity entity,
const std::string & componentName ) const
这是这个函数的调用关系图:

◆ registerComponent()

template<typename T>
void MQEngine::ComponentReflection::registerComponent ( const std::string & name)
private
这是这个函数的调用关系图:

◆ removeComponent()

void MQEngine::ComponentReflection::removeComponent ( entt::registry & registry,
entt::entity entity,
const std::string & componentName ) const
这是这个函数的调用关系图:

◆ setComponentField()

void MQEngine::ComponentReflection::setComponentField ( entt::registry & registry,
entt::entity entity,
const std::string & componentName,
const std::string & fieldName,
const ComponentValue & value ) const
这是这个函数的调用关系图:

类成员变量说明

◆ m_componentInfos

std::unordered_map<std::string, ComponentInfo> MQEngine::ComponentReflection::m_componentInfos
private

该类的文档由以下文件生成: