QxOrm  1.4.8
C++ Object Relational Mapping library
qx::serialization::helper::QxSerializeCheckInstance Class Reference

qx::serialization::helper::QxSerializeCheckInstance : check instance during serialization process to avoid infinite loop with circular references (using RAII) More...

#include <QxSerializeCheckInstance.h>

List of all members.

Public Types

typedef QPair< std::shared_ptr
< qx::QxSqlRelationLinked >
, QString > 
type_hierarchy

Public Member Functions

 QxSerializeCheckInstance (const void *pInstance, qx::IxClass *pClass)
virtual ~QxSerializeCheckInstance ()

Static Public Member Functions

static bool contains (const void *pInstance, qx::IxClass *pClass)
static bool isRoot ()
static type_hierarchy getHierarchy ()
static void setHierarchy (const type_hierarchy &hierarchy)

Protected Attributes

qptrdiff m_pInstance
 Instance associated to this helper class.
Qt::HANDLE m_lThreadId
 Thread id associated to this helper class.
qx::IxClassm_pClass
 Class associated to this helper class.

Static Protected Attributes

static QSet< QPair< Qt::HANDLE,
QPair< qptrdiff, qx::IxClass * > > > 
m_lstInstanceByThread
 List of all instances currently used by a serialization process.
static QHash< Qt::HANDLE, int > m_hashLevelByThread
 Manage how deep level is serialization process.
static QHash< Qt::HANDLE,
type_hierarchy
m_hashHierarchyByThread
 Store current hierarchy used by serialization process.
static QMutex m_mutex
 Mutex => qx::serialization::helper::QxSerializeCheckInstance is thread-safe.

Detailed Description

qx::serialization::helper::QxSerializeCheckInstance : check instance during serialization process to avoid infinite loop with circular references (using RAII)

Definition at line 65 of file QxSerializeCheckInstance.h.


Member Typedef Documentation


Constructor & Destructor Documentation

qx::serialization::helper::QxSerializeCheckInstance::QxSerializeCheckInstance ( const void *  pInstance,
qx::IxClass pClass 
)
virtual qx::serialization::helper::QxSerializeCheckInstance::~QxSerializeCheckInstance ( ) [virtual]

Member Function Documentation

static bool qx::serialization::helper::QxSerializeCheckInstance::contains ( const void *  pInstance,
qx::IxClass pClass 
) [static]
static type_hierarchy qx::serialization::helper::QxSerializeCheckInstance::getHierarchy ( ) [static]
static bool qx::serialization::helper::QxSerializeCheckInstance::isRoot ( ) [static]
static void qx::serialization::helper::QxSerializeCheckInstance::setHierarchy ( const type_hierarchy hierarchy) [static]

Member Data Documentation

Store current hierarchy used by serialization process.

Definition at line 76 of file QxSerializeCheckInstance.h.

Manage how deep level is serialization process.

Definition at line 75 of file QxSerializeCheckInstance.h.

QSet< QPair<Qt::HANDLE, QPair<qptrdiff, qx::IxClass *> > > qx::serialization::helper::QxSerializeCheckInstance::m_lstInstanceByThread [static, protected]

List of all instances currently used by a serialization process.

Definition at line 74 of file QxSerializeCheckInstance.h.

Thread id associated to this helper class.

Definition at line 80 of file QxSerializeCheckInstance.h.

Class associated to this helper class.

Definition at line 81 of file QxSerializeCheckInstance.h.

Instance associated to this helper class.

Definition at line 79 of file QxSerializeCheckInstance.h.


The documentation for this class was generated from the following file: