Fix build without features.cborstreamwriter
Change-Id: I970d21d7ac97a602a5f374f6c89cd4bfdcd847b8 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
This commit is contained in:
parent
35608c0761
commit
832d3b482e
@ -1220,11 +1220,13 @@ QDebug operator<<(QDebug dbg, const QCborArray &a)
|
||||
#endif
|
||||
|
||||
#ifndef QT_NO_DATASTREAM
|
||||
#if QT_CONFIG(cborstreamwriter)
|
||||
QDataStream &operator<<(QDataStream &stream, const QCborArray &value)
|
||||
{
|
||||
stream << value.toCborValue().toCbor();
|
||||
return stream;
|
||||
}
|
||||
#endif
|
||||
|
||||
QDataStream &operator>>(QDataStream &stream, QCborArray &value)
|
||||
{
|
||||
|
@ -301,7 +301,9 @@ Q_CORE_EXPORT QDebug operator<<(QDebug, const QCborArray &a);
|
||||
#endif
|
||||
|
||||
#ifndef QT_NO_DATASTREAM
|
||||
#if QT_CONFIG(cborstreamwriter)
|
||||
Q_CORE_EXPORT QDataStream &operator<<(QDataStream &, const QCborArray &);
|
||||
#endif
|
||||
Q_CORE_EXPORT QDataStream &operator>>(QDataStream &, QCborArray &);
|
||||
#endif
|
||||
|
||||
|
@ -1764,11 +1764,13 @@ QDebug operator<<(QDebug dbg, const QCborMap &m)
|
||||
#endif
|
||||
|
||||
#ifndef QT_NO_DATASTREAM
|
||||
#if QT_CONFIG(cborstreamwriter)
|
||||
QDataStream &operator<<(QDataStream &stream, const QCborMap &value)
|
||||
{
|
||||
stream << value.toCborValue().toCbor();
|
||||
return stream;
|
||||
}
|
||||
#endif
|
||||
|
||||
QDataStream &operator>>(QDataStream &stream, QCborMap &value)
|
||||
{
|
||||
|
@ -357,7 +357,9 @@ Q_CORE_EXPORT QDebug operator<<(QDebug, const QCborMap &m);
|
||||
#endif
|
||||
|
||||
#ifndef QT_NO_DATASTREAM
|
||||
#if QT_CONFIG(cborstreamwriter)
|
||||
Q_CORE_EXPORT QDataStream &operator<<(QDataStream &, const QCborMap &);
|
||||
#endif
|
||||
Q_CORE_EXPORT QDataStream &operator>>(QDataStream &, QCborMap &);
|
||||
#endif
|
||||
|
||||
|
@ -3164,11 +3164,13 @@ QDebug operator<<(QDebug dbg, QCborKnownTags tag)
|
||||
#endif
|
||||
|
||||
#ifndef QT_NO_DATASTREAM
|
||||
#if QT_CONFIG(cborstreamwriter)
|
||||
QDataStream &operator<<(QDataStream &stream, const QCborValue &value)
|
||||
{
|
||||
stream << QCborValue(value).toCbor();
|
||||
return stream;
|
||||
}
|
||||
#endif
|
||||
|
||||
QDataStream &operator>>(QDataStream &stream, QCborValue &value)
|
||||
{
|
||||
|
@ -487,7 +487,9 @@ Q_CORE_EXPORT QDebug operator<<(QDebug, const QCborValue &v);
|
||||
#endif
|
||||
|
||||
#ifndef QT_NO_DATASTREAM
|
||||
#if QT_CONFIG(cborstreamwriter)
|
||||
Q_CORE_EXPORT QDataStream &operator<<(QDataStream &, const QCborValue &);
|
||||
#endif
|
||||
Q_CORE_EXPORT QDataStream &operator>>(QDataStream &, QCborValue &);
|
||||
#endif
|
||||
|
||||
|
@ -337,6 +337,7 @@ bool QShaderDescription::isValid() const
|
||||
|| !d->combinedImageSamplers.isEmpty() || !d->storageImages.isEmpty();
|
||||
}
|
||||
|
||||
#if QT_CONFIG(cborstreamwriter)
|
||||
/*!
|
||||
\return a serialized binary version of the data in CBOR (Concise Binary
|
||||
Object Representation) format.
|
||||
@ -347,6 +348,7 @@ QByteArray QShaderDescription::toCbor() const
|
||||
{
|
||||
return QCborValue::fromJsonValue(d->makeDoc().object()).toCbor();
|
||||
}
|
||||
#endif
|
||||
|
||||
/*!
|
||||
\return a serialized JSON text version of the data.
|
||||
|
@ -69,7 +69,9 @@ public:
|
||||
|
||||
bool isValid() const;
|
||||
|
||||
#if QT_CONFIG(cborstreamwriter)
|
||||
QByteArray toCbor() const;
|
||||
#endif
|
||||
void serialize(QDataStream *stream) const;
|
||||
QByteArray toJson() const;
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user