13#include <private/qcborvalue_p.h>
14#include <private/qjson_p.h>
251 return a ?
a->elements.size() : 0;
269 return a ==
nullptr ||
a->elements.isEmpty();
280 if (!
a || i < 0 || i >=
a->elements.size())
307 return at(
a ? (
a->elements.size() - 1) : 0);
340 if (!
a || i < 0 || i >=
a->elements.size())
376 if (!
a || i < 0 || i >=
a->elements.size())
395 detach(
a->elements.size() + 1);
484 return !rhs.a->elements.size();
486 return !lhs.a->elements.size();
487 if (lhs.a->elements.size() != rhs.a->elements.size())
490 for (
qsizetype i = 0;
i < lhs.a->elements.size(); ++
i) {
491 if (lhs.a->valueAt(
i) != rhs.a->valueAt(
i))
499 return lhs == rhs.toArray();
1077#if !defined(QT_NO_DEBUG_STREAM) && !defined(QT_JSON_READONLY)
1082 dbg <<
"QJsonArray()";
1087 dbg.nospace() <<
"QJsonArray("
1094#ifndef QT_NO_DATASTREAM
const char * constData() const noexcept
Returns a pointer to the const data stored in the byte array.
static QCborArray fromJsonArray(const QJsonArray &array)
Converts all JSON items found in the array array to CBOR using QCborValue::fromJson(),...
\inmodule QtCore\reentrant
static QCborValue fromJsonValue(const QJsonValue &v)
Converts the JSON value contained in v into its corresponding CBOR value and returns it.
\inmodule QtCore\reentrant
\inmodule QtCore\reentrant
void insert(qsizetype i, const QJsonValue &value)
Inserts value at index position i in the array.
static QJsonArray fromStringList(const QStringList &list)
Converts the string list list to a QJsonArray.
~QJsonArray()
Deletes the array.
bool contains(const QJsonValue &element) const
Returns true if the array contains an occurrence of value, otherwise false.
static QJsonArray fromVariantList(const QVariantList &list)
Converts the variant list list to a QJsonArray.
QJsonValueRef operator[](qsizetype i)
Returns the value at index position i as a modifiable reference.
bool isEmpty() const
Returns true if the object is empty.
QJsonArray()
Creates an empty array.
friend class QJsonValueRef
QJsonValue takeAt(qsizetype i)
Removes the item at index position i and returns it.
QJsonValue first() const
Returns the first value stored in the array.
qsizetype size() const
Returns the number of values stored in the array.
void removeAt(qsizetype i)
Removes the value at index position i.
void replace(qsizetype i, const QJsonValue &value)
Replaces the item at index position i with value.
QJsonArray & operator=(const QJsonArray &other) noexcept
Assigns other to this array.
void append(const QJsonValue &value)
Inserts value at the end of the array.
QJsonValue at(qsizetype i) const
Returns a QJsonValue representing the value for index i.
QVariantList toVariantList() const
Converts this object to a QVariantList.
QJsonValue last() const
Returns the last value stored in the array.
void prepend(const QJsonValue &value)
Inserts value at the beginning of the array.
\inmodule QtCore\reentrant
QJsonArray array() const
Returns the QJsonArray contained in the document.
static QJsonValue fromTrustedCbor(const QCborValue &v)
static QJsonArray toJsonArray(const QVariantList &list)
static void arrayToJson(const QCborContainerPrivate *a, QByteArray &json, int indent, bool compact=false)
\inmodule QtCore \reentrant
\inmodule QtCore\reentrant
const_iterator constBegin() const noexcept
const_iterator constEnd() const noexcept
QSet< QString >::iterator it
Combined button and popup list for selecting options.
EGLOutputLayerEXT EGLint EGLAttrib value
[5]
size_t qHashRange(InputIterator first, InputIterator last, size_t seed=0) noexcept(noexcept(qHash(*first)))
QDebug operator<<(QDebug dbg, const QJsonArray &a)
QDataStream & operator>>(QDataStream &stream, QJsonArray &array)
bool comparesEqual(const QJsonArray &lhs, const QJsonArray &rhs) noexcept
size_t qHash(const QJsonArray &array, size_t seed)
GLsizei const GLfloat * v
[13]
GLboolean GLboolean GLboolean GLboolean a
[7]
GLenum GLuint GLintptr GLsizeiptr size
[1]
static Q_CONSTINIT QBasicAtomicInteger< unsigned > seed
static const QTextHtmlElement elements[Html_NumElements]