![]() |
Qt 6.x
The Qt SDK
|
#include <qarraydata.h>
Classes | |
struct | AlignmentDummy |
Static Public Member Functions | |
static QPair< QTypedArrayData *, T * > | allocate (qsizetype capacity, AllocationOption option=QArrayData::KeepSize) |
static QPair< QTypedArrayData *, T * > | reallocateUnaligned (QTypedArrayData *data, T *dataPointer, qsizetype capacity, AllocationOption option) |
static void | deallocate (QArrayData *data) noexcept |
static T * | dataStart (QArrayData *data, qsizetype alignment) noexcept |
![]() | |
static Q_CORE_EXPORT void * | allocate (QArrayData **pdata, qsizetype objectSize, qsizetype alignment, qsizetype capacity, AllocationOption option=QArrayData::KeepSize) noexcept |
static Q_CORE_EXPORT QPair< QArrayData *, void * > | reallocateUnaligned (QArrayData *data, void *dataPointer, qsizetype objectSize, qsizetype newCapacity, AllocationOption option) noexcept |
static Q_CORE_EXPORT void | deallocate (QArrayData *data, qsizetype objectSize, qsizetype alignment) noexcept |
Additional Inherited Members | |
![]() | |
enum | AllocationOption { Grow , KeepSize } |
enum | GrowthPosition { GrowsAtEnd , GrowsAtBeginning } |
enum | ArrayOption { ArrayOptionDefault = 0 , CapacityReserved = 0x1 } |
![]() | |
qsizetype | allocatedCapacity () noexcept |
qsizetype | constAllocatedCapacity () const noexcept |
bool | ref () noexcept |
Returns true if sharing took place. | |
bool | deref () noexcept |
Returns false if deallocation is necessary. | |
bool | isShared () const noexcept |
bool | needsDetach () const noexcept |
qsizetype | detachCapacity (qsizetype newSize) const noexcept |
![]() | |
QBasicAtomicInt | ref_ |
ArrayOptions | flags |
qsizetype | alloc |
Definition at line 96 of file qarraydata.h.
|
inlinestatic |
Definition at line 101 of file qarraydata.h.
References QArrayData::allocate(), capacity, d, Q_ALIGNOF, and qMakePair().
Referenced by QByteArray::QByteArray(), QByteArray::QByteArray(), QByteArray::QByteArray(), QList< T >::QList(), QArrayDataPointer< T >::allocateGrow(), QList< T >::clear(), QtPrivate::QPodArrayOps< T >::eraseIf(), QV4::Heap::SharedArrayBuffer::init(), QList< T >::operator=(), and QByteArray::qCompress().
|
inlinestaticnoexcept |
Definition at line 127 of file qarraydata.h.
References alignment, and Q_ASSERT.
Referenced by QArrayData::allocate(), and QArrayDataPointer< T >::freeSpaceAtBegin().
|
inlinestaticnoexcept |
Definition at line 121 of file qarraydata.h.
References QArrayData::deallocate().
Referenced by QStringHashNode::~QStringHashNode().
|
inlinestatic |
Definition at line 113 of file qarraydata.h.
References capacity, qMakePair(), and QArrayData::reallocateUnaligned().
Referenced by QtPrivate::QPodArrayOps< T >::reallocate(), and QtPrivate::QMovableArrayOps< T >::reallocate().