#ifndef PACKETREADER_H #define PACKETREADER_H #include #include class PacketReader { public: PacketReader(const QByteArray &buffer); PacketReader(const quint8 *data, int size); quint32 readU32(); bool readBytes(quint8 *output, int size); QString readString(int maxSize); private: const quint8 *m_pointer; const quint8 *m_end; }; #endif // PACKETREADER_H