Is used to store the type and the address of all previously serialized objects in a map.
More...
template<typename Derived>
struct mira::Serializer< Derived >::AObject
Is used to store the type and the address of all previously serialized objects in a map.
The type is an id that is obtained by the typeId(). typeId() gives a unique id that is unique for a single run of the program. It may change between different starts of the application and is only used to check for the same types here. And to resolve the following case
class Class1
{
{
}
int i
}
class Class2 {
Class1 c;
{
}
}
When serialized, Class2::c has the same address as Class1::i. If we would use the address only, we cannot distinguish between both, therefore we use the typeId which will be different, since Class2::c is of type Class1 and Class1:i is of type int.