Qt 4.8
Macros | Typedefs | Functions
qplugin.h File Reference
#include <QtCore/qobject.h>
#include <QtCore/qpointer.h>

Go to the source code of this file.

Macros

#define Q_EXPORT_PLUGIN(PLUGIN)   Q_EXPORT_PLUGIN2(PLUGIN, PLUGIN)
 
#define Q_EXPORT_PLUGIN2(PLUGIN, PLUGINCLASS)
 
#define Q_EXPORT_STATIC_PLUGIN(PLUGIN)   Q_EXPORT_STATIC_PLUGIN2(PLUGIN, PLUGIN)
 
#define Q_EXPORT_STATIC_PLUGIN2(PLUGIN, PLUGINCLASS)
 
#define Q_EXTERN_C   extern "C"
 
#define Q_IMPORT_PLUGIN(PLUGIN)
 
#define Q_PLUGIN_INSTANCE(IMPLEMENTATION)
 
#define Q_PLUGIN_VERIFICATION_DATA
 
#define Q_PLUGIN_VERIFICATION_SECTION
 
#define Q_STANDARD_CALL
 
#define QPLUGIN_DEBUG_STR   "true"
 
#define QPLUGIN_SECTION_DEBUG_STR   ".debug"
 

Typedefs

typedef QObject *(* QtPluginInstanceFunction) ()
 

Macro Definition Documentation

◆ Q_EXPORT_PLUGIN

#define Q_EXPORT_PLUGIN (   PLUGIN)    Q_EXPORT_PLUGIN2(PLUGIN, PLUGIN)

Definition at line 84 of file qplugin.h.

◆ Q_EXPORT_PLUGIN2

#define Q_EXPORT_PLUGIN2 (   PLUGIN,
  PLUGINCLASS 
)
Value:
Q_PLUGIN_VERIFICATION_SECTION Q_PLUGIN_VERIFICATION_DATA \
Q_EXTERN_C Q_DECL_EXPORT \
const char * Q_STANDARD_CALL qt_plugin_query_verification_data() \
{ return qt_plugin_verification_data; } \
Q_EXTERN_C Q_DECL_EXPORT QT_PREPEND_NAMESPACE(QObject) * Q_STANDARD_CALL qt_plugin_instance() \
Q_PLUGIN_INSTANCE(PLUGINCLASS)
#define Q_STANDARD_CALL
Definition: qplugin.h:133
The QObject class is the base class of all Qt objects.
Definition: qobject.h:111
#define Q_DECL_EXPORT
This macro marks a symbol for shared library export (see sharedlibrary.
Definition: qglobal.h:1288
#define QT_PREPEND_NAMESPACE(name)
This macro qualifies identifier with the full namespace.
Definition: qglobal.h:87
#define Q_PLUGIN_VERIFICATION_SECTION
Definition: qplugin.h:127

Definition at line 136 of file qplugin.h.

Referenced by AVBackend::availableMimeTypes(), QMeeGoGraphicsSystemPlugin::create(), EGLNullWSScreenPlugin::create(), QCocoaIntegrationPlugin::create(), QUIKitIntegrationPlugin::create(), QAhiScreenPlugin::create(), PvrEglScreenPlugin::create(), DirectFBScreenDriverPlugin::create(), QmlJSDebugger::QDeclarativeInspectorPlugin::deactivate(), QMultiInputContextPlugin::description(), QSQLite2DriverPlugin::keys(), QSQLiteDriverPlugin::keys(), QTcpServerConnection::newConnection(), QmlOstPlugin::readyRead(), and qmlshaderspluginPlugin::registerTypes().

◆ Q_EXPORT_STATIC_PLUGIN

#define Q_EXPORT_STATIC_PLUGIN (   PLUGIN)    Q_EXPORT_STATIC_PLUGIN2(PLUGIN, PLUGIN)

◆ Q_EXPORT_STATIC_PLUGIN2

#define Q_EXPORT_STATIC_PLUGIN2 (   PLUGIN,
  PLUGINCLASS 
)

Definition at line 144 of file qplugin.h.

◆ Q_EXTERN_C

#define Q_EXTERN_C   extern "C"

Definition at line 56 of file qplugin.h.

◆ Q_IMPORT_PLUGIN

#define Q_IMPORT_PLUGIN (   PLUGIN)
Value:
extern QT_PREPEND_NAMESPACE(QObject) *qt_plugin_instance_##PLUGIN(); \
class Static##PLUGIN##PluginInstance{ \
public: \
Static##PLUGIN##PluginInstance() { \
qRegisterStaticPluginInstanceFunction(qt_plugin_instance_##PLUGIN); \
} \
}; \
static Static##PLUGIN##PluginInstance static##PLUGIN##Instance;
The QObject class is the base class of all Qt objects.
Definition: qobject.h:111
#define QT_PREPEND_NAMESPACE(name)
This macro qualifies identifier with the full namespace.
Definition: qglobal.h:87

Definition at line 66 of file qplugin.h.

◆ Q_PLUGIN_INSTANCE

#define Q_PLUGIN_INSTANCE (   IMPLEMENTATION)
Value:
{ \
if (!_instance) \
_instance = new IMPLEMENTATION; \
return _instance; \
}
The QObject class is the base class of all Qt objects.
Definition: qobject.h:111
The QPointer class is a template class that provides guarded pointers to QObject. ...
Definition: qpointer.h:54
#define QT_PREPEND_NAMESPACE(name)
This macro qualifies identifier with the full namespace.
Definition: qglobal.h:87

Definition at line 76 of file qplugin.h.

◆ Q_PLUGIN_VERIFICATION_DATA

#define Q_PLUGIN_VERIFICATION_DATA
Value:
static const char qt_plugin_verification_data[] = \
"pattern=QT_PLUGIN_VERIFICATION_DATA\n" \
"version=" QT_VERSION_STR "\n" \
"debug=" QPLUGIN_DEBUG_STR "\n" \
"buildkey=" QT_BUILD_KEY;
#define QT_BUILD_KEY
Definition: qglobal.h:1254
#define QPLUGIN_DEBUG_STR
Definition: qplugin.h:113
#define QT_VERSION_STR
This macro expands to a string that specifies Qt&#39;s version number (for example, "4.
Definition: qglobal.h:47

Definition at line 116 of file qplugin.h.

◆ Q_PLUGIN_VERIFICATION_SECTION

#define Q_PLUGIN_VERIFICATION_SECTION

Definition at line 127 of file qplugin.h.

◆ Q_STANDARD_CALL

#define Q_STANDARD_CALL

Definition at line 133 of file qplugin.h.

◆ QPLUGIN_DEBUG_STR

#define QPLUGIN_DEBUG_STR   "true"

Definition at line 113 of file qplugin.h.

◆ QPLUGIN_SECTION_DEBUG_STR

#define QPLUGIN_SECTION_DEBUG_STR   ".debug"

Definition at line 114 of file qplugin.h.

Typedef Documentation

◆ QtPluginInstanceFunction

typedef QObject*(* QtPluginInstanceFunction) ()

Definition at line 62 of file qplugin.h.

Function Documentation

◆ qRegisterStaticPluginInstanceFunction()

void Q_CORE_EXPORT qRegisterStaticPluginInstanceFunction ( QtPluginInstanceFunction  function)
related