1// Copyright (C) 2015 basysKom GmbH, opensource@basyskom.com
2// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only
3
4#ifndef QOPCUAPROVIDER_H
5#define QOPCUAPROVIDER_H
6
7#include <QtOpcUa/qopcuaglobal.h>
8
9#include <QtCore/qhash.h>
10#include <QtCore/qobject.h>
11#include <QtCore/qvariant.h>
12#include <QtCore/qmap.h> // for QVariantMap
13
14QT_BEGIN_NAMESPACE
15
16class QOpcUaPlugin;
17class QOpcUaClient;
18
19class Q_OPCUA_EXPORT QOpcUaProvider : public QObject
20{
21 Q_OBJECT
22
23public:
24 static QStringList availableBackends();
25
26 explicit QOpcUaProvider(QObject *parent = nullptr);
27 ~QOpcUaProvider() override;
28
29 Q_INVOKABLE QOpcUaClient *createClient(const QString &backend, const QVariantMap &backendProperties = QVariantMap());
30
31private:
32 QMultiHash<QString, QOpcUaPlugin *> m_plugins;
33};
34
35QT_END_NAMESPACE
36
37#endif // QOPCUAPROVIDER_H
38

source code of qtopcua/src/opcua/core/qopcuaprovider.h