Coverage Report

Created: 2026-08-17 07:50

next uncovered line (L), next uncovered region (R), next uncovered branch (B)
/src/qtbase/src/gui/kernel/qgenericplugin.cpp
Line
Count
Source
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
// Qt-Security score:significant reason:default
4
5
#include "qgenericplugin.h"
6
7
QT_BEGIN_NAMESPACE
8
9
/*!
10
    \class QGenericPlugin
11
    \ingroup plugins
12
    \inmodule QtGui
13
14
    \brief The QGenericPlugin class is an abstract base class for
15
    plugins.
16
17
    A mouse plugin can be created by subclassing
18
    QGenericPlugin and reimplementing the pure virtual create()
19
    function. By exporting the derived class using the
20
    Q_PLUGIN_METADATA() macro, The default implementation of the
21
    QGenericPluginFactory class will automatically detect the plugin and
22
    load the driver into the server application at run-time. See \l
23
    {How to Create Qt Plugins} for details.
24
25
    The json metadata file should contain a list of keys supported by this
26
    plugin.
27
28
    \sa QGenericPluginFactory
29
*/
30
31
/*!
32
    Constructs a plugin with the given \a parent.
33
34
    Note that this constructor is invoked automatically by the
35
    moc generated code that exports the plugin, so there is no need for calling it
36
    explicitly.
37
*/
38
QGenericPlugin::QGenericPlugin(QObject *parent)
39
0
    : QObject(parent)
40
0
{
41
0
}
42
43
/*!
44
    Destroys the plugin.
45
46
    Note that Qt destroys a plugin automatically when it is no longer
47
    used, so there is no need for calling the destructor explicitly.
48
*/
49
QGenericPlugin::~QGenericPlugin()
50
0
{
51
0
}
52
53
/*!
54
    \fn QObject* QGenericPlugin::create(const QString &key, const QString& specification)
55
56
    Implement this function to create a driver matching the type
57
    specified by the given \a key and \a specification parameters. Note that
58
    keys are case-insensitive.
59
*/
60
61
QT_END_NAMESPACE
62
63
#include "moc_qgenericplugin.cpp"