![]() |
hivemind 1.0.0
|
Rflection is made possible by the help of the ISValue class and the type classes. More...
#include <serializer.h>
Public Member Functions | |
virtual ISProperties | GetProperty () |
GetProperty enables the serializer to deal with composite type like objects and members. | |
virtual void | CreateObject () |
For future expansion. | |
virtual rapidjson::Value | GetName (rapidjson::Document &d) |
For future expansion. | |
virtual rapidjson::Value | ToDom (rapidjson::Document &d) |
ToDom is the function that enables the serializer to take data from the application to the JSON file. | |
virtual void | FromDom (rapidjson::Value &v, rapidjson::Document &d) |
FromDom is the function that enables the serializer to get data out of the JSON file and put it in the application. | |
Rflection is made possible by the help of the ISValue class and the type classes.
Each type needs their own implementation for reflection to work. At the moment only JSON is supported by this library. Making the library work for other format than JSON would require implementing each type again for the new format by in theory would not impact the application programmers at all
Definition at line 41 of file serializer.h.
|
inlinevirtual |
For future expansion.
Reimplemented in Json::ISObject< T >, and Json::ISMember< T >.
Definition at line 55 of file serializer.h.
|
virtual |
FromDom is the function that enables the serializer to get data out of the JSON file and put it in the application.
Reimplemented in Json::ISInt, Json::ISFloat, Json::ISDouble, Json::ISBool, Json::ISString, Json::ISObject< T >, Json::ISObjectVector< T >, Json::ISObjVecVec< T >, Json::ISMemVecVec< T >, Json::ISMember< T >, Json::ISMemberVector< T >, Json::ISIntVector, Json::ISFloatVector, and Json::ISDoubleVector.
Definition at line 113 of file serializer.cpp.
References GetProperty().
|
inlinevirtual |
For future expansion.
Typeid is mostly implemented for future expansion, but it helps with making the JSON file more readable for humans.
Reimplemented in Json::ISObject< T >, and Json::ISMember< T >.
Definition at line 60 of file serializer.h.
Referenced by Json::serialize(), and ToDom().
|
inlinevirtual |
GetProperty enables the serializer to deal with composite type like objects and members.
Definition at line 48 of file serializer.h.
Referenced by Json::deserialize(), FromDom(), Json::serialize(), and ToDom().
|
virtual |
ToDom is the function that enables the serializer to take data from the application to the JSON file.
Reimplemented in Json::ISInt, Json::ISFloat, Json::ISDouble, Json::ISBool, Json::ISString, Json::ISObject< T >, Json::ISObjectVector< T >, Json::ISObjVecVec< T >, Json::ISMemVecVec< T >, Json::ISMember< T >, Json::ISMemberVector< T >, Json::ISIntVector, Json::ISFloatVector, and Json::ISDoubleVector.
Definition at line 95 of file serializer.cpp.
References GetName(), and GetProperty().