openMSX
|
#include <serialize.hh>
Public Member Functions | |
template<typename Base , typename T > | |
void | serializeInlinedBase (T &t, unsigned version) |
template<typename T , typename... Args> | |
void | serializeWithID (const char *tag, const T &t, Args...) |
void | serialize_blob (const char *tag, const void *data, size_t len, bool diff=true) |
template<typename T > | |
void | serialize (const char *tag, const T &t) |
template<typename T > | |
void | serializePointerID (const char *tag, const T &t) |
template<typename T > | |
void | serializePolymorphic (const char *tag, const T &t) |
template<typename T > | |
void | serializeOnlyOnce (const char *tag, const T &t) |
void | serializeChar (const char *tag, char c) |
![]() | |
template<typename Base , typename T > | |
void | serializeBase (T &t) |
Is this archive a loader or a saver. More... | |
template<typename Base , typename T > | |
void | serializeInlinedBase (T &t, unsigned version) |
Serialize the base class of this classtype. More... | |
bool | isReverseSnapshot () const |
Is this a reverse-snapshot? More... | |
template<typename T > | |
void | attribute (const char *name, T &t) |
Load/store an attribute from/in the archive. More... | |
void | attribute (const char *name, const char *value) |
bool | hasAttribute (const char *) |
Check the presence of a (optional) attribute. More... | |
template<typename T > | |
std::optional< T > | findAttributeAs (const char *) |
Optimization: combination of hasAttribute() and getAttribute(). More... | |
int | countChildren () const |
Count the number of child tags. More... | |
void | beginTag (const char *) |
Indicate begin of a tag. More... | |
void | endTag (const char *) |
Indicate begin of a tag. More... | |
![]() | |
bool | versionAtLeast (unsigned, unsigned) const |
bool | versionBelow (unsigned, unsigned) const |
void | skipSection (bool) |
template<typename T > | |
unsigned | generateId (const T *p) |
template<typename T > | |
unsigned | getId (const T *p) |
Protected Member Functions | |
OutputArchiveBase ()=default | |
![]() | |
Derived & | self () |
Returns a reference to the most derived class. More... | |
![]() | |
OutputArchiveBase2 ()=default | |
Additional Inherited Members | |
![]() | |
static constexpr bool | NEED_VERSION = true |
Does this archive store version information. More... | |
static constexpr bool | TRANSLATE_ENUM_TO_STRING = false |
Does this archive store enums as strings. More... | |
static constexpr bool | CAN_HAVE_OPTIONAL_ATTRIBUTES = false |
Some archives (like XML archives) can store optional attributes. More... | |
static constexpr bool | CAN_COUNT_CHILDREN = false |
Some archives (like XML archives) can count the number of subtags that belong to the current tag. More... | |
![]() | |
static constexpr bool | IS_LOADER = false |
Definition at line 437 of file serialize.hh.
|
protecteddefault |
|
inline |
Definition at line 469 of file serialize.hh.
References openmsx::ArchiveBase< Derived >::beginTag(), and openmsx::ArchiveBase< Derived >::endTag().
void openmsx::OutputArchiveBase< Derived >::serialize_blob | ( | const char * | tag, |
const void * | data, | ||
size_t | len, | ||
bool | diff = true |
||
) |
Definition at line 76 of file serialize.cc.
References openmsx::MemBuffer< T, ALIGNMENT >::data().
|
inline |
Definition at line 497 of file serialize.hh.
References openmsx::ArchiveBase< Derived >::beginTag(), and openmsx::ArchiveBase< Derived >::endTag().
|
inline |
Definition at line 441 of file serialize.hh.
References t.
|
inline |
Definition at line 489 of file serialize.hh.
References openmsx::OutputArchiveBase2::getId(), openmsx::OutputArchiveBase< Derived >::serializeWithID(), and t.
|
inline |
Definition at line 476 of file serialize.hh.
References openmsx::ArchiveBase< Derived >::beginTag(), and openmsx::ArchiveBase< Derived >::endTag().
|
inline |
Definition at line 483 of file serialize.hh.
References openmsx::PolymorphicSaverRegistry< Archive >::save().
|
inline |
Definition at line 456 of file serialize.hh.
References openmsx::ArchiveBase< Derived >::beginTag(), and openmsx::ArchiveBase< Derived >::endTag().
Referenced by openmsx::OutputArchiveBase< Derived >::serializeOnlyOnce().