32#if (QT_VERSION >= QT_VERSION_CHECK(4, 6, 0))
33#ifndef _QX_SERIALIZE_QDATASTREAM_QSCOPEDPOINTER_H_
34#define _QX_SERIALIZE_QDATASTREAM_QSCOPEDPOINTER_H_
47#include <QtCore/qdatastream.h>
48#include <QtCore/qscopedpointer.h>
51QDataStream &
operator<< (QDataStream & stream,
const QScopedPointer<T> & t)
53 qint8 iIsNull = (t ? 0 : 1);
55 if (t) { stream << (* t); }
60QDataStream &
operator>> (QDataStream & stream, QScopedPointer<T> & t)
64 if (! iIsNull) { t.reset(
new T()); stream >> (* t); }
QDataStream & operator<<(QDataStream &stream, const QScopedPointer< T > &t)
QDataStream & operator>>(QDataStream &stream, QScopedPointer< T > &t)