Qt
Internal/Contributor docs for the Qt SDK. Note: These are NOT official API docs; those are found at https://doc.qt.io/
Loading...
Searching...
No Matches
qgenericplugin.cpp
Go to the documentation of this file.
1
// Copyright (C) 2016 The Qt Company Ltd.
2
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only
3
4
#
include
"qgenericplugin.h"
5
6
QT_BEGIN_NAMESPACE
7
8
/*!
9
\class QGenericPlugin
10
\ingroup plugins
11
\inmodule QtGui
12
13
\brief The QGenericPlugin class is an abstract base class for
14
plugins.
15
16
A mouse plugin can be created by subclassing
17
QGenericPlugin and reimplementing the pure virtual create()
18
function. By exporting the derived class using the
19
Q_PLUGIN_METADATA() macro, The default implementation of the
20
QGenericPluginFactory class will automatically detect the plugin and
21
load the driver into the server application at run-time. See \l
22
{How to Create Qt Plugins} for details.
23
24
The json metadata file should contain a list of keys supported by this
25
plugin.
26
27
\sa QGenericPluginFactory
28
*/
29
30
/*!
31
Constructs a plugin with the given \a parent.
32
33
Note that this constructor is invoked automatically by the
34
moc generated code that exports the plugin, so there is no need for calling it
35
explicitly.
36
*/
37
QGenericPlugin::QGenericPlugin(QObject *parent)
38
: QObject(parent)
39
{
40
}
41
42
/*!
43
Destroys the plugin.
44
45
Note that Qt destroys a plugin automatically when it is no longer
46
used, so there is no need for calling the destructor explicitly.
47
*/
48
QGenericPlugin::~QGenericPlugin()
49
{
50
}
51
52
/*!
53
\fn QObject* QGenericPlugin::create(const QString &key, const QString& specification)
54
55
Implement this function to create a driver matching the type
56
specified by the given \a key and \a specification parameters. Note that
57
keys are case-insensitive.
58
*/
59
60
QT_END_NAMESPACE
61
62
#
include
"moc_qgenericplugin.cpp"
QPlatformGraphicsBufferHelper
\inmodule QtGui
qtbase
src
gui
kernel
qgenericplugin.cpp
Generated on
for Qt by
1.14.0