class
TRTTIType
template<typename Type, typename BaseType, typename MyRTTIType>Allows you to provide a run-time type information for a specific class, along with support for serialization/deserialization.
Derive from this class and return the that class from IReflectable::getRTTI. This way you can separate serialization logic from the actual class you're serializing.
This class will provide a way to register individual fields in the class, together with ways to read and write them, as well a providing information about class hierarchy, and run-time type checking.
Public
Constructors
Methods
staticInstance
Returns a singleton of this RTTI type.
GetDefaultObject
Returns the default constructed object of this type.
Will return null if the class is abstract.
GetDerivedClasses
Returns RTTI type information for all classes that derive from the class that owns this RTTI type.
GetBaseClass
Returns RTTI type information for the class that owns this RTTI type.
If the class has not base type, null is returned instead.
IsDerivedFrom
Returns true if current RTTI class is derived from . (Or if it is the same type as base)
RegisterDerivedClassInternal
Called by the RTTI system when a class is first found in order to form child/parent class hierarchy.
CloneInternal
Constucts a cloned version of the underlying class.
The cloned version will not have any field information and should instead be used for passing to various RTTIField methods during serialization/deserialization. This allows each object instance to have a unique places to store temporary instance-specific data.
InitializeDefaultObject
Constructs the default object for the type, if it's possible to construct one.
Protected
Methods
OnOperationStarted
OnOperationEnded
NotifyOperationStarted
Called before any operation that is iterating over the type's fields starts.
NotifyOperationEnded
Called after any operation that is iterating over the type's fields ends.