Important: Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct
QQueue peek ?
-
I am using QQueue:
typedef QQueue<QJsonObject> mqueJSON;
Presently I am using dequeue to extract an item from the queue, however what I really want to do is peek at the queue and not remove an item from its position in the queue until I want to remove it.
Is there any way to do this?
-
https://doc.qt.io/qt-5/qqueue.html#head
if(!mqueJSON.isEmpty()){ const auto peekItem = mqueJSON.head(); ... }
-
https://doc.qt.io/qt-5/qqueue.html#head
if(!mqueJSON.isEmpty()){ const auto peekItem = mqueJSON.head(); ... }
-
@J-Hilk , thank you.
-
Reading the documentation is really hard...