1// Copyright (C) 2017 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 QOPCUAMONITORINGPARAMETERS_P_H
5#define QOPCUAMONITORINGPARAMETERS_P_H
6
7//
8// W A R N I N G
9// -------------
10//
11// This file is not part of the Qt API. It exists purely as an
12// implementation detail. This header file may change from version to
13// version without notice, or even be removed.
14//
15// We mean it.
16//
17
18#include <QtOpcUa/qopcuamonitoringparameters.h>
19
20#include <QtCore/qshareddata.h>
21#include <QtCore/private/qglobal_p.h>
22
23QT_BEGIN_NAMESPACE
24
25class Q_OPCUA_EXPORT QOpcUaMonitoringParametersPrivate : public QSharedData
26{
27public:
28
29 QOpcUaMonitoringParametersPrivate()
30 : samplingInterval(0)
31 , queueSize(0)
32 , discardOldest(true)
33 , monitoringMode(QOpcUaMonitoringParameters::MonitoringMode::Reporting)
34 , subscriptionId(0)
35 , monitoredItemId(0)
36 , publishingInterval(0)
37 , lifetimeCount(150) // Must be at least three times the maxKeepAliveCount (OPC-UA part 4, page 76).
38 , maxKeepAliveCount(50) // Allow 50 publishing intervals before a keepalive is expected to reduce the network traffic.
39 , maxNotificationsPerPublish(0)
40 , priority(0)
41 , publishingEnabled(true)
42 , statusCode(QOpcUa::UaStatusCode::BadNoEntryExists)
43 , shared(QOpcUaMonitoringParameters::SubscriptionType::Shared)
44 {}
45
46 // MonitoredItem
47 double samplingInterval;
48 QVariant filter;
49 QVariant filterResult;
50 quint32 queueSize;
51 bool discardOldest;
52 QOpcUaMonitoringParameters::MonitoringMode monitoringMode;
53 QString indexRange;
54
55 // Subscription
56 quint32 subscriptionId;
57 quint32 monitoredItemId;
58 double publishingInterval;
59 quint32 lifetimeCount;
60 quint32 maxKeepAliveCount;
61 quint32 maxNotificationsPerPublish;
62 quint8 priority;
63 bool publishingEnabled;
64
65 // Qt OPC UA specific
66 QOpcUa::UaStatusCode statusCode;
67 QOpcUaMonitoringParameters::SubscriptionType shared;
68};
69
70QT_END_NAMESPACE
71
72#endif // QOPCUAMONITORINGPARAMETERS_P_H
73

source code of qtopcua/src/opcua/client/qopcuamonitoringparameters_p.h