32#ifndef _QX_DAO_IS_DIRTY_H_
33#define _QX_DAO_IS_DIRTY_H_
39#include <QtCore/qstringlist.h>
54inline void is_dirty(
const T & obj1,
const T & obj2, QStringList & lstDiff);
60 static void compare(
const T & obj1,
const T & obj2, QStringList & lstDiff)
66 if (pId && (! pId->
isEqual((& obj1), (& obj2)))) { lstDiff.append(pId->
getKey()); }
71 {
if (p && (! p->
isEqual((& obj1), (& obj2)))) { lstDiff.append(p->
getKey()); } }
80 static void compare(
const T & obj1,
const T & obj2, QStringList & lstDiff)
86 typename T::const_iterator it2 = obj2.begin();
88 for (
typename T::const_iterator it1 = obj1.begin(); it1 != obj1.end(); ++it1)
90 QStringList lstDiffItem;
92 if (lstDiffItem.count() > 0) { lstDiff.append(QString::number(lCurrIndex) +
"|" + lstDiffItem.join(
"|")); }
103 static void compare(
const T & obj1,
const T & obj2, QStringList & lstDiff)
112 static void compare(
const T & obj1,
const T & obj2, QStringList & lstDiff)
117 type_dao_3::compare(obj1, obj2, lstDiff);
123inline void is_dirty(
const T & obj1,
const T & obj2, QStringList & lstDiff)
Common interface for all relationships defined between 2 classes (or between 2 tables in database)
Concrete SQL query builder by class with a cache mechanism to backup and restore queries already buil...
qx::IxDataMember : common interface for all class properties registered into QxOrm context
virtual bool isEqual(const void *pOwner1, const void *pOwner2) const =0
IxDataMember * nextData(long &l) const
IxDataMember * getDataId() const
qx::QxSqlQueryBuilder_Count<T> : concrete SQL query builder for class T to build a COUNT SQL query
qx::trait::generic_container<T> : provide some tools to manage all containers without knowing its typ...
qx::trait::is_container<T>::value : return true if T is a container from stl, boost,...
qx::trait::is_qx_registered<T>::value : return true if T is registered into QxOrm context to provide ...
qx::trait::is_smart_ptr<T>::value : return true if T is a smart-pointer of boost, Qt or QxOrm librari...
void is_dirty(const T &obj1, const T &obj2, QStringList &lstDiff)
Root namespace for all QxOrm library features.
static void compare(const T &obj1, const T &obj2, QStringList &lstDiff)
static void compare(const T &obj1, const T &obj2, QStringList &lstDiff)
static void compare(const T &obj1, const T &obj2, QStringList &lstDiff)
static void compare(const T &obj1, const T &obj2, QStringList &lstDiff)
qx::trait::generic_container<T> : provide some tools to manage all containers without knowing its typ...
qx::trait::is_qx_registered<T>::value : return true if T is registered into QxOrm context to provide ...