open62541pp 0.16.0
C++ wrapper of open62541
|
#include <subscription.hpp>
High-level subscription class.
The API is symmetric for both Server and Client, although servers don't use the subscription mechanism of OPC UA to transport notifications of data changes and events. Instead MonitoredItems are registered locally. Notifications are then forwarded to user-defined callbacks instead of a remote client. The subscriptionId
for servers is always 0U
.
Use the free functions in the opcua::services namespace for more advanced usage:
Definition at line 43 of file subscription.hpp.
|
inlinenoexcept |
Wrap an existing subscription.
The subscriptionId
is ignored and set to 0U
for servers.
Definition at line 47 of file subscription.hpp.
|
inlinenoexcept |
Get the server/client instance.
Definition at line 52 of file subscription.hpp.
Referenced by opcua::Subscription< Connection >::deleteSubscription(), opcua::Subscription< Connection >::setPublishingMode(), opcua::Subscription< Connection >::setSubscriptionParameters(), opcua::Subscription< Connection >::subscribeDataChange(), and opcua::Subscription< Connection >::subscribeEvent().
|
inlinenoexcept |
Get the server/client instance.
Definition at line 57 of file subscription.hpp.
|
inlinenoexcept |
Get the server-assigned identifier of this subscription.
Definition at line 62 of file subscription.hpp.
Referenced by opcua::Subscription< Connection >::deleteSubscription(), opcua::Subscription< Connection >::setPublishingMode(), opcua::Subscription< Connection >::setSubscriptionParameters(), opcua::Subscription< Connection >::subscribeDataChange(), and opcua::Subscription< Connection >::subscribeEvent().
std::vector< MonitoredItem< Connection > > opcua::Subscription< Connection >::getMonitoredItems | ( | ) |
Get all local monitored items.
|
inline |
Modify this subscription.
Definition at line 72 of file subscription.hpp.
|
inline |
Enable/disable publishing of notification messages.
Definition at line 82 of file subscription.hpp.
|
inline |
Create a monitored item for data change notifications.
Definition at line 87 of file subscription.hpp.
Referenced by opcua::Subscription< Connection >::subscribeDataChange().
|
inline |
Create a monitored item for data change notifications (default settings).
The monitoring mode is set to MonitoringMode::Reporting and the default open62541 MonitoringParametersEx are used.
Definition at line 110 of file subscription.hpp.
|
inline |
Create a monitored item for event notifications.
Definition at line 121 of file subscription.hpp.
Referenced by opcua::Subscription< Connection >::subscribeEvent().
|
inline |
Create a monitored item for event notifications (default settings).
The monitoring mode is set to MonitoringMode::Reporting and the default open62541 MonitoringParametersEx are used.
Definition at line 143 of file subscription.hpp.
|
inline |
Delete this subscription.
Definition at line 153 of file subscription.hpp.