diff options
Diffstat (limited to 'helpers.cpp')
-rw-r--r-- | helpers.cpp | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/helpers.cpp b/helpers.cpp index ceb4454..c77c054 100644 --- a/helpers.cpp +++ b/helpers.cpp @@ -18,6 +18,7 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ +#include <QtCore/QDataStream> #include "helpers.h" static QByteArray reverse(const QByteArray &ba) @@ -66,3 +67,9 @@ QByteArray gatouuid_to_bytearray(const GatoUUID &uuid, bool use_uuid16, bool use return reverse(uuid.toRfc4122()); } + +void write_gatouuid(QDataStream &s, const GatoUUID &uuid, bool use_uuid16, bool use_uuid32) +{ + QByteArray bytes = gatouuid_to_bytearray(uuid, use_uuid16, use_uuid32); + s.writeRawData(bytes.constData(), bytes.size()); +} |