7#include <QtCore/qcborvalue.h>
9#include <initializer_list>
24 QCborValueRef
item {};
150 bool isEmpty()
const {
return size() == 0; }
184#if 0 && __has_include(<compare>)
188 if (
c > 0)
return std::strong_ordering::greater;
189 if (
c == 0)
return std::strong_ordering::equivalent;
190 return std::strong_ordering::less;
196 {
return !(*
this ==
other); }
222 bool empty()
const {
return isEmpty(); }
243 friend QCborValueRef;
252 :
n(-1), container(
a.
d.take()),
t(Array)
256#if QT_VERSION < QT_VERSION_CHECK(7, 0, 0) && !defined(QT_BOOTSTRAPPED)
257inline QCborArray QCborValueRef::toArray()
const
259 return concrete().toArray();
264 return concrete().toArray(
a);
280#if !defined(QT_NO_DEBUG_STREAM)
284#ifndef QT_NO_DATASTREAM
285#if QT_CONFIG(cborstreamwriter)
const QCborValueRef reference
ConstIterator & operator-=(qsizetype j)
Makes the iterator go back by j positions.
QCborValueConstRef operator*() const
Returns the current item.
qsizetype operator-(ConstIterator j) const
Returns the offset of this iterator relative to other.
bool operator>(const ConstIterator &other) const
Returns true if the entry in the array pointed to by this iterator occurs after the entry pointed to ...
ConstIterator operator--(int)
This is an overloaded member function, provided for convenience. It differs from the above function o...
bool operator>=(const ConstIterator &other) const
Returns true if the entry in the array pointed to by this iterator occurs after or is the same entry ...
constexpr ConstIterator()=default
Constructs an uninitialized iterator.
bool operator<(const Iterator &other) const
bool operator<(const ConstIterator &other) const
Returns true if the entry in the array pointed to by this iterator occurs before the entry pointed to...
bool operator!=(const ConstIterator &o) const
Returns true if o points to a different entry in the array than this iterator; otherwise returns fals...
ConstIterator & operator+=(qsizetype j)
Advances the iterator by j positions.
qsizetype difference_type
bool operator<=(const Iterator &other) const
bool operator==(const Iterator &o) const
bool operator>=(const Iterator &other) const
constexpr ConstIterator(const ConstIterator &)=default
Constructs a copy of other.
const QCborValueRef * pointer
ConstIterator operator+(qsizetype j) const
Returns an iterator to the item at a position j steps forward from this iterator.
ConstIterator & operator--()
The prefix {–} operator, {–it}, makes the preceding item current and returns this iterator.
std::random_access_iterator_tag iterator_category
A synonym for {std::random_access_iterator_tag} indicating this iterator is a random access iterator.
const QCborValueConstRef * operator->() const
Returns a pointer to the current item.
ConstIterator & operator=(const ConstIterator &other)
Makes this iterator a copy of other and returns a reference to this iterator.
bool operator==(const ConstIterator &o) const
Returns true if other points to the same entry in the array as this iterator; otherwise returns false...
bool operator!=(const Iterator &o) const
QCborValueConstRef operator[](qsizetype j) const
Returns the item at a position j steps forward from the item pointed to by this iterator.
const QCborValue value_type
ConstIterator operator++(int)
This is an overloaded member function, provided for convenience. It differs from the above function o...
ConstIterator & operator++()
The prefix {++} operator, {++it}, advances the iterator to the next item in the array and returns thi...
bool operator<=(const ConstIterator &other) const
Returns true if the entry in the array pointed to by this iterator occurs before or is the same entry...
ConstIterator operator-(qsizetype j) const
Returns an iterator to the item at a position j steps backward from this iterator.
bool operator>(const Iterator &other) const
qsizetype operator-(Iterator j) const
Returns the offset of this iterator relative to other.
constexpr Iterator()=default
Constructs an uninitialized iterator.
QCborValueRef operator[](qsizetype j) const
Returns a modifiable reference to the item at a position j steps forward from the item pointed to by ...
bool operator<(const Iterator &other) const
bool operator<=(const Iterator &other) const
Iterator operator-(qsizetype j) const
Returns an iterator to the item at position j steps backward from this iterator.
bool operator==(const ConstIterator &o) const
Returns true if other points to the same entry in the array as this iterator; otherwise returns false...
Iterator operator--(int)
This is an overloaded member function, provided for convenience. It differs from the above function o...
Iterator & operator=(const Iterator &other)
Makes this iterator a copy of other and returns a reference to this iterator.
bool operator>(const Iterator &other) const
Iterator & operator++()
The prefix {++} operator, {++it}, advances the iterator to the next item in the array and returns thi...
Iterator operator++(int)
This is an overloaded member function, provided for convenience. It differs from the above function o...
QCborValueRef operator*() const
Returns a modifiable reference to the current item.
constexpr Iterator(const Iterator &)=default
Makes a copy of other.
bool operator<(const ConstIterator &other) const
Returns true if the entry in the array pointed to by this iterator occurs before the entry pointed to...
bool operator>=(const Iterator &other) const
Iterator & operator--()
The prefix {–} operator, {–it}, makes the preceding item current and returns this iterator.
Iterator & operator+=(qsizetype j)
Advances the iterator by j positions.
qsizetype difference_type
Iterator operator+(qsizetype j) const
Returns an iterator to the item at position j steps forward from this iterator.
std::random_access_iterator_tag iterator_category
A synonym for {std::random_access_iterator_tag} indicating this iterator is a random access iterator.
bool operator>=(const ConstIterator &other) const
Returns true if the entry in the array pointed to by this iterator occurs after or is the same entry ...
QCborValueRef * operator->()
bool operator>(const ConstIterator &other) const
Returns true if the entry in the array pointed to by this iterator occurs after the entry pointed to ...
bool operator!=(const ConstIterator &o) const
Returns true if other points to a different entry in the array than this iterator; otherwise returns ...
bool operator!=(const Iterator &o) const
bool operator<=(const ConstIterator &other) const
Returns true if the entry in the array pointed to by this iterator occurs before or is the same entry...
Iterator & operator-=(qsizetype j)
Makes the iterator go back by j positions.
bool operator==(const Iterator &o) const
const QCborValueConstRef * operator->() const
Returns a pointer to a modifiable reference to the current item.
\inmodule QtCore\reentrant
QCborValue & reference
A typedef to {QCborValue &}, for compatibility with generic algorithms.
QCborValue takeLast()
Removes the last item in the array and returns it.
const_iterator constEnd() const
Returns an array iterator pointing to just after the last element in this array.
const_iterator constBegin() const
Returns an array iterator pointing to the first item in this array.
QCborValue takeAt(qsizetype i)
Removes the item at position i from the array and returns it.
QCborValue takeFirst()
Removes the first item in the array and returns it, making the second element become the first.
void append(QCborValue &&value)
Appends value into the array after all other elements it may already contain.
iterator begin()
Returns an array iterator pointing to the first item in this array.
bool operator==(const QCborArray &other) const noexcept
Compares this array and other, comparing each element in sequence, and returns true if both arrays co...
bool operator!=(const QCborArray &other) const noexcept
Compares this array and other, comparing each element in sequence, and returns true if the two arrays...
const value_type * const_pointer
A typedef to {const QCborValue *}, for compatibility with generic algorithms.
void pop_front()
Synonym for removeFirst().
const_iterator begin() const
Returns an array iterator pointing to the first item in this array.
void append(const QCborValue &value)
ConstIterator const_iterator
A synonym to QCborArray::ConstIterator.
const_iterator end() const
Returns an array iterator pointing to just after the last element in this array.
void push_back(const QCborValue &t)
Synonym for append().
QCborValue toCborValue() const
Explicitly construcuts a \l QCborValue object that represents this array.
Iterator iterator
A synonym to QCborArray::Iterator.
void removeLast()
Removes the last item in the array.
iterator insert(const_iterator before, const QCborValue &value)
This is an overloaded member function, provided for convenience. It differs from the above function o...
value_type * pointer
A typedef to {QCborValue *}, for compatibility with generic algorithms.
QCborValue first() const
Returns the first QCborValue of this array.
const_iterator cend() const
Returns an array iterator pointing to just after the last element in this array.
void push_front(const QCborValue &t)
Synonym for prepend().
const QCborValue & const_reference
A typedef to {const QCborValue &}, for compatibility with generic algorithms.
QCborArray & operator+=(const QCborValue &v)
Appends v to this array and returns a reference to this array.
QCborValueRef last()
Returns a reference to the last QCborValue of this array.
void prepend(QCborValue &&value)
Prepends value into the array before any other elements it may already contain.
QCborValue last() const
Returns the last QCborValue of this array.
iterator erase(iterator it)
void removeFirst()
Removes the first item in the array, making the second element become the first.
qsizetype difference_type
A typedef to qsizetype.
void swap(QCborArray &other) noexcept
Swaps the contents of this object and other.
QCborValue extract(ConstIterator it)
Extracts a value from the array at the position indicated by iterator it and returns the value so ext...
bool empty() const
Synonym for isEmpty().
QCborValue value_type
The type of values that can be held in a QCborArray: that is, QCborValue.
iterator insert(iterator before, const QCborValue &value)
const_iterator cbegin() const
Returns an array iterator pointing to the first item in this array.
QCborArray operator+(const QCborValue &v) const
Returns a new QCborArray containing the same elements as this array, plus v appended as the last elem...
qsizetype size_type
A typedef to qsizetype.
iterator erase(const_iterator it)
Removes the element pointed to by the array iterator it from this array, then returns an iterator to ...
bool operator<(const QCborArray &other) const
Compares this array and other, comparing each element in sequence, and returns true if this array sho...
void pop_back()
Synonym for removeLast().
QCborValueRef operator[](qsizetype i)
Returns a reference to the QCborValue element at position i in the array.
QCborValueRef first()
Returns a reference to the first QCborValue of this array.
const QCborValue operator[](qsizetype i) const
Returns the QCborValue element at position i in the array.
QCborArray & operator<<(const QCborValue &v)
Appends v to this array and returns a reference to this array.
void prepend(const QCborValue &value)
iterator end()
Returns an array iterator pointing to just after the last element in this array.
QCborArray toArray() const
QCborValue concrete() const noexcept
\inmodule QtCore\reentrant
QCborArray toArray() const
\inmodule QtCore\reentrant
\inmodule QtCore\reentrant
qsizetype size() const noexcept
list append(new Employee("Blackpool", "Stephen"))
cache insert(employee->id(), employee)
QSet< QString >::iterator it
Combined button and popup list for selecting options.
Q_CORE_EXPORT QDataStream & operator>>(QDataStream &, QCborArray &)
Q_CORE_EXPORT size_t qHash(const QCborArray &array, size_t seed=0)
Q_CORE_EXPORT QDebug operator<<(QDebug, const QCborArray &a)
#define Q_DECL_PURE_FUNCTION
EGLOutputLayerEXT EGLint EGLAttrib value
[5]
static bool contains(const QJsonArray &haystack, unsigned needle)
GLsizei const GLfloat * v
[13]
GLboolean GLboolean GLboolean GLboolean a
[7]
GLenum GLuint GLintptr GLsizeiptr size
[1]
static Q_CONSTINIT QBasicAtomicInteger< unsigned > seed
QtPrivate::QRegularExpressionMatchIteratorRangeBasedForIterator begin(const QRegularExpressionMatchIterator &iterator)
static int compare(quint64 a, quint64 b)