|
Gromacs
2023.4
|
#include <gromacs/utility/include/gromacs/utility/iserializer.h>
Inherited by gmx::FileIOXdrSerializer, gmx::InMemoryDeserializer, and gmx::InMemorySerializer.
Interface for types that convert standard data types into a form suitable for storage or transfer.
Different implementations could suit MPI, file I/O, or in-memory conversion.
Public Member Functions | |
| virtual bool | reading () const =0 |
| Returns whether the serializer is reading or writing, because details like memory management vary accordingly. | |
| template<typename EnumType > | |
| void | doEnumAsInt (EnumType *enumValue) |
| Serialize enum value with underlying type int. | |
| template<typename EnumType > | |
| void | doEnumArrayAsInt (EnumType *values, int elements) |
| Serialize array of enum values with underlying type. | |
| virtual void | doBool (bool *value)=0 |
| Serialize values of different types. | |
| virtual void | doUChar (unsigned char *value)=0 |
| virtual void | doChar (char *value)=0 |
| virtual void | doUShort (unsigned short *value)=0 |
| virtual void | doInt (int *value)=0 |
| virtual void | doInt32 (int32_t *value)=0 |
| virtual void | doInt64 (int64_t *value)=0 |
| virtual void | doFloat (float *value)=0 |
| virtual void | doDouble (double *value)=0 |
| virtual void | doReal (real *value)=0 |
| virtual void | doIvec (ivec *value)=0 |
| virtual void | doRvec (rvec *value)=0 |
| virtual void | doString (std::string *value)=0 |
| virtual void | doOpaque (char *data, std::size_t size)=0 |
| void | doBoolArray (bool *values, int elements) |
| Serialize arrays of values of different types. | |
| virtual void | doCharArray (char *values, int elements) |
| virtual void | doUCharArray (unsigned char *values, int elements) |
| void | doUShortArray (unsigned short *values, int elements) |
| void | doIntArray (int *values, int elements) |
| void | doInt32Array (int32_t *values, int elements) |
| void | doInt64Array (int64_t *values, int elements) |
| void | doFloatArray (float *values, int elements) |
| void | doDoubleArray (double *values, int elements) |
| void | doRealArray (real *values, int elements) |
| void | doIvecArray (ivec *values, int elements) |
| virtual void | doRvecArray (rvec *values, int elements) |
1.8.5