REST-for-Physics
v2.3
Rare Event Searches ToolKit for Physics
|
This namespace serves for the reflection functionality. More...
Data Structures | |
struct | DataType_Info |
class | TRestReflector |
Functions | |
TRestReflector | Assembly (const std::string &typeName) |
Assembly an object of type: typeName, returning the allocated memory address and size. | |
void | CloneAny (const TRestReflector &from, const TRestReflector &to) |
Deep copy the content of object from to to More... | |
template<typename T > | |
TClass * | GetClassQuick () |
Get the type of a "class" object, returning the wrapped type identifier "TClass". More... | |
TClass * | GetClassQuick (std::string type) |
template<typename T > | |
std::string | GetTypeName () |
Get the type name of an object. | |
template<class T > | |
std::string | GetTypeName (T obj) |
Get the type name of an object. | |
TRestReflector | WrapType (const std::string &typeName) |
Wrap information an object of type: typeName, memory is not allocated. | |
Variables | |
EXTERN_DEF std::map< void *, TClass * > | RESTListOfClasses_typeid |
EXTERN_DEF std::map< std::string, TClass * > | RESTListOfClasses_typename |
This namespace serves for the reflection functionality.
void REST_Reflection::CloneAny | ( | const TRestReflector & | from, |
const TRestReflector & | to | ||
) |
Deep copy the content of object from
to to
Calls RESTVirtualConverter::CloneObj(). The actual methods are registered in converter.cpp If not registered, you can add it manually with AddConverter() macro
Definition at line 268 of file TRestReflector.cxx.
TClass* REST_Reflection::GetClassQuick | ( | ) |
Get the type of a "class" object, returning the wrapped type identifier "TClass".
Quicker than TClass::GetClass() since it stores limited objects in the std::map, no need to iterate all the valid types. Do not call this method before main function.
Definition at line 258 of file TRestReflector.h.
|
inline |
Wrap the std::string type name into ROOT type identifier "TClass"
Quicker than TClass::GetClass() since it stores limited objects in the std::map, no need to iterate all the valid types. Do not call this method before main function.
Definition at line 239 of file TRestReflector.h.