diff --git a/src/bluetooth/qbluetoothuuid.h b/src/bluetooth/qbluetoothuuid.h index 25c7896c5cb3895a7ee4e1f1088ecc4477d8715b..dd587694ca46db4799d1aa21ab8344a4f1cda9c8 100644 --- a/src/bluetooth/qbluetoothuuid.h +++ b/src/bluetooth/qbluetoothuuid.h @@ -396,6 +396,18 @@ public: static QString descriptorToString(DescriptorType uuid); }; +#ifndef QT_NO_DATASTREAM +inline QDataStream &operator<<(QDataStream &s, const QBluetoothUuid &uuid) +{ + return s << static_cast<const QUuid &>(uuid); +} + +inline QDataStream &operator>>(QDataStream &s, QBluetoothUuid &uuid) +{ + return s >> static_cast<QUuid &>(uuid); +} +#endif + #ifndef QT_NO_DEBUG_STREAM /// TODO: Move implementation to .cpp, uninline and add Q_BLUETOOTH_EXPORT for Qt 6 inline QDebug operator<<(QDebug debug, const QBluetoothUuid &uuid)