![]() |
Qt 6.x
The Qt SDK
|
#include <qsharedpointer_impl.h>
Inheritance diagram for QtSharedPointer::ExternalRefCountData:
Collaboration diagram for QtSharedPointer::ExternalRefCountData:Public Types | |
| typedef void(* | DestroyerFn) (ExternalRefCountData *) |
Public Member Functions | |
| ExternalRefCountData (DestroyerFn d) | |
| ExternalRefCountData (Qt::Initialization) | |
| ~ExternalRefCountData () | |
| void | destroy () |
| Q_CORE_EXPORT void | setQObjectShared (const QObject *, bool enable) |
| Q_CORE_EXPORT void | checkQObjectShared (const QObject *) |
| void | checkQObjectShared (...) |
| void | setQObjectShared (...) |
| void * | operator new (std::size_t)=delete |
| void * | operator new (std::size_t, void *ptr) noexcept |
| void | operator delete (void *ptr) |
| void | operator delete (void *, void *) |
Static Public Member Functions | |
| static Q_CORE_EXPORT ExternalRefCountData * | getAndRef (const QObject *) |
Public Attributes | |
| QBasicAtomicInt | weakref |
| QBasicAtomicInt | strongref |
| DestroyerFn | destroyer |
Definition at line 98 of file qsharedpointer_impl.h.
| typedef void(* QtSharedPointer::ExternalRefCountData::DestroyerFn) (ExternalRefCountData *) |
Definition at line 100 of file qsharedpointer_impl.h.
|
inline |
Definition at line 105 of file qsharedpointer_impl.h.
References QBasicAtomicInteger< T >::storeRelaxed(), strongref, and weakref.
Here is the call graph for this function:
|
inline |
Definition at line 111 of file qsharedpointer_impl.h.
|
inline |
Definition at line 112 of file qsharedpointer_impl.h.
References QBasicAtomicInteger< T >::loadRelaxed(), Q_ASSERT, strongref, and weakref.
Here is the call graph for this function:
|
inline |
Definition at line 121 of file qsharedpointer_impl.h.
This function is called when a QSharedPointer is created from a QWeakPointer
We check that the QWeakPointer was really created from a QSharedPointer, and not from a QObject.
Definition at line 1397 of file qsharedpointer.cpp.
References qWarning.
|
inline |
Definition at line 114 of file qsharedpointer_impl.h.
References destroyer.
Referenced by QtSharedPointer::ExternalRefCountWithContiguousData< T >::create().
Here is the caller graph for this function:
|
static |
Definition at line 1403 of file qsharedpointer.cpp.
References d, QObjectPrivate::get(), Q_ASSERT, Q_ASSERT_X, QBasicAtomicInteger< T >::ref(), ret, Qt::Uninitialized, and weakref.
Referenced by QV4::QV4QPointer< T >::init().
Here is the call graph for this function:
Here is the caller graph for this function:Definition at line 131 of file qsharedpointer_impl.h.
Definition at line 130 of file qsharedpointer_impl.h.
References ptr().
Here is the call graph for this function:
|
inlinedelete |
|
inlinenoexcept |
Definition at line 129 of file qsharedpointer_impl.h.
References ptr().
Here is the call graph for this function:
|
inline |
Definition at line 122 of file qsharedpointer_impl.h.
| QT_BEGIN_NAMESPACE void QtSharedPointer::ExternalRefCountData::setQObjectShared | ( | const QObject * | , |
| bool | enable | ||
| ) |
This function is called for a just-created QObject obj, to enable the use of QSharedPointer and QWeakPointer in the future.
Definition at line 1387 of file qsharedpointer.cpp.
Referenced by QSharedPointer< T >::internalConstruct().
Here is the caller graph for this function:| DestroyerFn QtSharedPointer::ExternalRefCountData::destroyer |
Definition at line 103 of file qsharedpointer_impl.h.
Referenced by destroy().
| QBasicAtomicInt QtSharedPointer::ExternalRefCountData::strongref |
Definition at line 102 of file qsharedpointer_impl.h.
Referenced by ExternalRefCountData(), ~ExternalRefCountData(), QObject::~QObject(), QV4::QV4QPointer< T >::data(), QSharedPointer< T >::internalSet(), QWeakPointer< T >::isNull(), QV4::QV4QPointer< T >::isNull(), and QSharedPointer< T >::ref().
| QBasicAtomicInt QtSharedPointer::ExternalRefCountData::weakref |
Definition at line 101 of file qsharedpointer_impl.h.
Referenced by ExternalRefCountData(), QWeakPointer< T >::QWeakPointer(), QWeakPointer< T >::QWeakPointer(), ~ExternalRefCountData(), QObject::~QObject(), QWeakPointer< T >::~QWeakPointer(), QV4::QV4QPointer< T >::destroy(), getAndRef(), and QSharedPointer< T >::ref().