The QDataStream class provides serialization of binary data to a QIODevice.
I have to populate a QByteArray with different data. So I'm using the QDataStream. QByteArray buffer; QDataStream stream(&buffer, …