Qt 6.x
The Qt SDK
Loading...
Searching...
No Matches
qobjectdefs.h File Reference
#include <QtCore/qnamespace.h>
#include <QtCore/qobjectdefs_impl.h>
#include <QtCore/qtmetamacros.h>
+ Include dependency graph for qobjectdefs.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  QMethodRawArguments
 
struct  QMetaMethodArgument
 
struct  QMetaMethodReturnArgument
 
class  QMetaObject
 \inmodule QtCore More...
 
struct  QMetaObject::SuperData
 
struct  QMetaObject::Data
 
struct  QtPrivate::HasQ_OBJECT_Macro< Object >
 

Namespaces

namespace  QtPrivate
 \macro QT_NAMESPACE
 
namespace  QtPrivate::Invoke
 

Macros

#define QMETHOD_CODE   0
 
#define QSLOT_CODE   1
 
#define QSIGNAL_CODE   2
 
#define QT_PREFIX_CODE(code, a)   QT_STRINGIFY(code) #a
 
#define QT_STRINGIFY_METHOD(a)   QT_PREFIX_CODE(QMETHOD_CODE, a)
 
#define QT_STRINGIFY_SLOT(a)   QT_PREFIX_CODE(QSLOT_CODE, a)
 
#define QT_STRINGIFY_SIGNAL(a)   QT_PREFIX_CODE(QSIGNAL_CODE, a)
 
#define QLOCATION   "\0" __FILE__ ":" QT_STRINGIFY(__LINE__)
 
#define METHOD(a)   qFlagLocation(QT_STRINGIFY_METHOD(a) QLOCATION)
 
#define SLOT(a)   qFlagLocation(QT_STRINGIFY_SLOT(a) QLOCATION)
 
#define SIGNAL(a)   qFlagLocation(QT_STRINGIFY_SIGNAL(a) QLOCATION)
 
#define Q_ARG(Type, data)   QtPrivate::Invoke::argument<Type>(QT_STRINGIFY(Type), data)
 
#define Q_RETURN_ARG(Type, data)   QtPrivate::Invoke::returnArgument<Type>(QT_STRINGIFY(Type), data)
 

Typedefs

template<typename... Args>
using QtPrivate::Invoke::AreOldStyleArgs = std::disjunction< std::is_base_of< QGenericArgument, Args >... >
 
template<typename T , typename... Args>
using QtPrivate::Invoke::IfNotOldStyleArgs = std::enable_if_t<!AreOldStyleArgs< Args... >::value, T >
 

Functions

Q_CORE_EXPORT const char * qFlagLocation (const char *method)
 
template<typename T >
constexpr const QMetaTypeInterfaceQtPrivate::qMetaTypeInterfaceForType ()
 
template<typename T >
QMetaMethodArgument QtPrivate::Invoke::argument (const char *name, const T &t)
 
template<typename T >
QMetaMethodReturnArgument QtPrivate::Invoke::returnArgument (const char *name, T &t)
 
template<typename T >
const char * QtPrivate::Invoke::typenameHelper (const T &)
 
template<typename T >
const voidQtPrivate::Invoke::dataHelper (const T &t)
 
template<typename T >
const QMetaTypeInterfaceQtPrivate::Invoke::metaTypeHelper (const T &)
 
const char * QtPrivate::Invoke::typenameHelper (QMetaMethodArgument a)
 
const voidQtPrivate::Invoke::dataHelper (QMetaMethodArgument a)
 
const QMetaTypeInterfaceQtPrivate::Invoke::metaTypeHelper (QMetaMethodArgument a)
 
const char * QtPrivate::Invoke::typenameHelper (const char *)=delete
 
template<typename T >
const voidQtPrivate::Invoke::dataHelper (const char *)=delete
 
const QMetaTypeInterfaceQtPrivate::Invoke::metaTypeHelper (const char *)=delete
 
const char * QtPrivate::Invoke::typenameHelper (const char16_t *)=delete
 
template<typename T >
const voidQtPrivate::Invoke::dataHelper (const char16_t *)=delete
 
const QMetaTypeInterfaceQtPrivate::Invoke::metaTypeHelper (const char16_t *)=delete
 
template<typename... Args>
auto QtPrivate::invokeMethodHelper (QMetaMethodReturnArgument r, const Args &... arguments)
 
template<typename T >
void qReturnArg (const T &&)=delete
 
template<typename T >
QMetaMethodReturnArgument qReturnArg (T &data)
 
void swap (QMetaObject::Connection &lhs, QMetaObject::Connection &rhs) noexcept
 

Macro Definition Documentation

◆ METHOD

#define METHOD (   a)    qFlagLocation(QT_STRINGIFY_METHOD(a) QLOCATION)

Definition at line 49 of file qobjectdefs.h.

◆ Q_ARG

#define Q_ARG (   Type,
  data 
)    QtPrivate::Invoke::argument<Type>(QT_STRINGIFY(Type), data)

Definition at line 62 of file qobjectdefs.h.

◆ Q_RETURN_ARG

#define Q_RETURN_ARG (   Type,
  data 
)    QtPrivate::Invoke::returnArgument<Type>(QT_STRINGIFY(Type), data)

Definition at line 63 of file qobjectdefs.h.

◆ QLOCATION

#define QLOCATION   "\0" __FILE__ ":" QT_STRINGIFY(__LINE__)

Definition at line 47 of file qobjectdefs.h.

◆ QMETHOD_CODE

#define QMETHOD_CODE   0

Definition at line 39 of file qobjectdefs.h.

◆ QSIGNAL_CODE

#define QSIGNAL_CODE   2

Definition at line 41 of file qobjectdefs.h.

◆ QSLOT_CODE

#define QSLOT_CODE   1

Definition at line 40 of file qobjectdefs.h.

◆ QT_PREFIX_CODE

#define QT_PREFIX_CODE (   code,
  a 
)    QT_STRINGIFY(code) #a

Definition at line 42 of file qobjectdefs.h.

◆ QT_STRINGIFY_METHOD

#define QT_STRINGIFY_METHOD (   a)    QT_PREFIX_CODE(QMETHOD_CODE, a)

Definition at line 43 of file qobjectdefs.h.

◆ QT_STRINGIFY_SIGNAL

#define QT_STRINGIFY_SIGNAL (   a)    QT_PREFIX_CODE(QSIGNAL_CODE, a)

Definition at line 45 of file qobjectdefs.h.

◆ QT_STRINGIFY_SLOT

#define QT_STRINGIFY_SLOT (   a)    QT_PREFIX_CODE(QSLOT_CODE, a)

Definition at line 44 of file qobjectdefs.h.

◆ SIGNAL

#define SIGNAL (   a)    qFlagLocation(QT_STRINGIFY_SIGNAL(a) QLOCATION)

Definition at line 52 of file qobjectdefs.h.

◆ SLOT

#define SLOT (   a)    qFlagLocation(QT_STRINGIFY_SLOT(a) QLOCATION)

Definition at line 51 of file qobjectdefs.h.

Function Documentation

◆ qFlagLocation()

Q_CORE_EXPORT const char * qFlagLocation ( const char *  method)

Definition at line 2419 of file qobject.cpp.

References method.

◆ qReturnArg() [1/2]

template<typename T >
void qReturnArg ( const T &&  )
delete

Referenced by wrapInFunction().

+ Here is the caller graph for this function:

◆ qReturnArg() [2/2]

template<typename T >
QMetaMethodReturnArgument qReturnArg ( T &  data)
inline

Definition at line 220 of file qobjectdefs.h.

References QtPrivate::Invoke::returnArgument().

+ Here is the call graph for this function:

◆ swap()

void swap ( QMetaObject::Connection lhs,
QMetaObject::Connection rhs 
)
inlinenoexcept

Definition at line 562 of file qobjectdefs.h.

References swap().

+ Here is the call graph for this function: