File indexing completed on 2025-03-09 03:55:00

0001 /* ============================================================
0002  *
0003  * This file is a part of digiKam project
0004  * https://www.digikam.org
0005  *
0006  * Date        : 16/08/2016
0007  * Description : Serialization utilities to help making long
0008  *               serialization platform independent
0009  *
0010  * SPDX-FileCopyrightText:      2016 by Omar Amin <Omar dot moh dot amin at gmail dot com>
0011  * SPDX-FileCopyrightText: 2016-2024 by Gilles Caulier <caulier dot gilles at gmail dot com>
0012  *
0013  * SPDX-License-Identifier: GPL-2.0-or-later
0014  *
0015  * ============================================================ */
0016 
0017 #include "qdatastreamoverloads.h"
0018 
0019 QDataStream& operator >> (QDataStream& dataStream,
0020                           unsigned long& in)
0021 {
0022     qint64 x;
0023     dataStream >> x;
0024     in = x;
0025 
0026     return dataStream;
0027 }
0028 
0029 QDataStream& operator << (QDataStream& dataStream,
0030                           const unsigned long& in)
0031 {
0032     qint64 x = in;
0033     dataStream << x;
0034 
0035     return dataStream;
0036 }