Qt
Internal/Contributor docs for the Qt SDK. <b>Note:</b> These are NOT official API docs; those are found <a href='https://doc.qt.io/'>here</a>.
Loading...
Searching...
No Matches
qpointer.h File Reference

(1219dbcd123a8001785a1e58452d9abfdfc43471)

#include <QtCore/qsharedpointer.h>
#include <QtCore/qtypeinfo.h>
+ Include dependency graph for qpointer.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  QPointer< T >
 

Macros

#define DECLARE_COMPARE_SET(T1, A1, T2, A2)
 
#define DECLARE_TEMPLATE_COMPARE_SET(T1, A1, T2, A2)
 

Functions

template<class T >
 Q_DECLARE_TYPEINFO_BODY (QPointer< T >, Q_RELOCATABLE_TYPE)
 
template<typename T >
QPointer< T > qPointerFromVariant (const QVariant &variant)
 

Macro Definition Documentation

◆ DECLARE_COMPARE_SET

#define DECLARE_COMPARE_SET ( T1,
A1,
T2,
A2 )
Value:
friend bool operator==(T1, T2) noexcept \
{ return A1 == A2; } \
friend bool operator!=(T1, T2) noexcept \
{ return A1 != A2; }
constexpr bool operator!=(const timespec &t1, const timespec &t2)
bool operator==(const QRandomGenerator &rng1, const QRandomGenerator &rng2)
Definition qrandom.cpp:1220

Definition at line 93 of file qpointer.h.

◆ DECLARE_TEMPLATE_COMPARE_SET

#define DECLARE_TEMPLATE_COMPARE_SET ( T1,
A1,
T2,
A2 )
Value:
template <typename X> \
friend bool operator==(T1, T2) noexcept \
{ return A1 == A2; } \
template <typename X> \
friend bool operator!=(T1, T2) noexcept \
{ return A1 != A2; }

Definition at line 99 of file qpointer.h.

Function Documentation

◆ Q_DECLARE_TYPEINFO_BODY()

template<class T >
Q_DECLARE_TYPEINFO_BODY ( QPointer< T > ,
Q_RELOCATABLE_TYPE  )

◆ qPointerFromVariant()

template<typename T >
QPointer< T > qPointerFromVariant ( const QVariant & variant)

Definition at line 119 of file qpointer.h.

References QtPrivate::EnableInternalData::internalData(), variant, and QtSharedPointer::weakPointerFromVariant_internal().

+ Here is the call graph for this function: