| MULTIBODY SIMULATION SOFTWARE - API documentation |
#include <CHstream.h>


Public Member Functions | |
| template<class T > | |
| ChStreamInBinary & | operator>> (T &obj) |
| ChStreamInBinary & | operator>> (char &Val) |
| ChStreamInBinary & | operator>> (bool &Val) |
| ChStreamInBinary & | operator>> (int &Val) |
| ChStreamInBinary & | operator>> (unsigned int &Val) |
| ChStreamInBinary & | operator>> (double &Val) |
| ChStreamInBinary & | operator>> (float &Val) |
| ChStreamInBinary & | operator>> (std::string &str) |
| ChStreamInBinary & | operator>> (char *str) |
| template<class T > | |
| void | GenericBinaryInput (T &ogg) |
| template<class t > | |
| t * | AbstractReadCreate (t **mObj) |
| template<class t > | |
| t * | AbstractReadAllCreate (t **mObj) |
| int | VersionRead () |
This is a base class for all BINARY INPUT streams, in a way such that the stream is platform indepent (see the 'little endian' stuff in 'floating point to persistent data' topics..) Defines some << operators from basic types, converting all them into calls to the Output() function. At least some inherited class should be used by the user in order to get some practical effect (file saving, etc.)
| t* chrono::ChStreamInBinary::AbstractReadAllCreate | ( | t ** | mObj | ) |
Extract an object from the archive, and assignes the pointer to it. This function can be used to load objects whose class is not known in advance (anyway, assuming the class had been registered with Chrono class factory registration). It _creates_ the object of the proper downcasted class, and deserializes it. Note: the object must be saved with ChStreamOutBinary::AbstractWrite() Also, the AbstractWrite()-AbstractReadCreate() mechanism avoids storing/creating multiple times the shared objects. Supports only objects with Chrono RTTI and serializer member StreamIN().
| t* chrono::ChStreamInBinary::AbstractReadCreate | ( | t ** | mObj | ) |
Extract an object from the archive, and assignes the pointer to it. This function can be used to load objects whose class is not known in advance (anyway, assuming the class had been registered with Chrono class factory registration). It _creates_ the object of the proper downcasted class, and deserializes it. Note: the object must be saved with ChStreamOutBinary::AbstractWrite() Also, the AbstractWrite()-AbstractReadCreate() mechanism avoids storing/creating multiple times the shared objects. Supports only objects with Chrono RTTI and serializer member StreamIN().
| void chrono::ChStreamInBinary::GenericBinaryInput | ( | T & | ogg | ) |
Generic operator for raw binary streaming of generic objects WARNING!!! raw byte streaming! If class 'T' contains double, int, long, etc, these may give problems when loading on another platform which has big-endian ordering, if generated on a little-edian platform...
| ChStreamInBinary& chrono::ChStreamInBinary::operator>> | ( | T & | obj | ) |
Generic >> operator for all classes which implement serialization by means of a method named 'void StreamIN(ChStreamInBinary&)'
| ChStreamInBinary & chrono::ChStreamInBinary::operator>> | ( | char & | Val | ) |
Specialized operators for basic primitives (numbers like long, double, int. etc., and booleans) Handle byte ordering issues in little.endian/big.endian representations, for cross platform portability.
| int chrono::ChStreamInBinary::VersionRead | ( | ) |
Some objects may write class version at the beginning of the streamed data, they can use this function to read class from stream.
CHRONO::ENGINE