You.i Engine
RTTISampleClass Class Reference

Detailed Description

This is a sample class to document the RTTI functions inserted into classes by the YI_TYPE_BASES(...) macro.

#include <utility/YiRtti.h>

Inheritance diagram for RTTISampleClass:

Public Member Functions

const CYIRuntimeTypeInfoGetRuntimeTypeInfo () const

Static Public Member Functions

static const CYIRuntimeTypeInfoTyped< RTTISampleClass, Base1, Base2, Base3 > & GetClassTypeInfo ()

Member Function Documentation

◆ GetClassTypeInfo()

static const CYIRuntimeTypeInfoTyped<RTTISampleClass, Base1, Base2, Base3>& RTTISampleClass::GetClassTypeInfo ( )

Returns the CYIRuntimeTypeInfoTyped object (which is a subclass of CYIRuntimeTypeInfo) associated with this class.

This function should be accessed statically using the :: operator.
If called on a pointer, the CYIRuntimeTypeInfoTyped object associated with the pointer type is returned, which may not match the runtime type of the pointed-to object.
std::cout << pNode->GetClassTypeInfo().GetName() << std::endl; // prints 'CYISceneNode'
std::cout << CYIPushButtonView::GetClassTypeInfo().GetName() << std::endl; // prints 'CYIPushButtonView'

◆ GetRuntimeTypeInfo()

const CYIRuntimeTypeInfo& RTTISampleClass::GetRuntimeTypeInfo ( ) const

Returns the CYIRuntimeTypeInfo object associated with this object. This function returns the runtime type associated with a specific object.


std::cout << pNode->GetRuntimeTypeInfo().GetName() << std::endl; // prints 'CYIPushButtonView'

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