This class provides an unique notification identifier. The ID is generated from the className, the devices specified by the selection criterion, and the properties that will be notified.
More...
#include <NotificationID.h>
|
| NotificationID (uint32_t idKey, const std::set< std::string > &deviceCol, const std::set< std::string > ¬ifiedPropertyCol, const std::string &globalDeviceName=std::string(), const std::set< std::string > ¬ifiedGlobalProperties=std::set< std::string >()) |
| Constructor. More...
|
|
| ~NotificationID () |
|
const std::set< std::string > & | getNotifiedPropertyCol () const |
| returns the set of properties corresponding to this notification ID More...
|
|
const std::set< std::string > & | getNotifiedGlobalProperties () const |
| returns the set of global properties corresponding to this notification ID More...
|
|
const std::set< std::string > & | getDeviceCol () const |
| returns the set of devices corresponding to this NotificationID More...
|
|
bool | hasGlobalDeviceNotification () const |
| returns true if the global device is part of this NotificationID.
|
|
const std::string & | getGlobalDeviceName () const |
| returns the name of the global device of this NotificationID, or empty string if the global device is not part of this notification.
|
|
uint32_t | getIDKey () const |
| returns the unique ID key, which identifies the notification ID and is the same for the server and the real-time side More...
|
|
bool | contains (const std::string &propName, const std::string &deviceName) const |
| This method checks whether the notification ID contains the given combination of property and device. More...
|
|
void | addDevice (const std::string &deviceName) |
| Adds a new device name to be notified. More...
|
|
void | addProperty (const std::string &propertyName) |
| This method adds a new class/property combination to be notified. More...
|
|
bool | matches (const std::set< std::string > ¬ifiedProperties, const std::set< std::string > &deviceNames, const std::set< std::string > ¬ifiedGlobalProperties, const std::string &globalDeviceName) const |
| Compares the content of this object to the given parameters. Returns true if they match.
|
|
This class provides an unique notification identifier. The ID is generated from the className, the devices specified by the selection criterion, and the properties that will be notified.
fesa::NotificationID::NotificationID |
( |
uint32_t |
idKey, |
|
|
const std::set< std::string > & |
deviceCol, |
|
|
const std::set< std::string > & |
notifiedPropertyCol, |
|
|
const std::string & |
globalDeviceName = std::string() , |
|
|
const std::set< std::string > & |
notifiedGlobalProperties = std::set<std::string>() |
|
) |
| |
Constructor.
- Parameters
-
idKey | the identifier of the notification |
deviceCol | names of the devices that will be notified |
notifiedPropertyCol | names of the properties that will be notified |
globalDeviceName | name of the global device that will be notified; leave empty if there is no global device notification |
notifiedGlobalProperties | names of the global properties that will be notified |
fesa::NotificationID::~NotificationID |
( |
| ) |
|
void fesa::NotificationID::addDevice |
( |
const std::string & |
deviceName | ) |
|
|
inline |
Adds a new device name to be notified.
- Parameters
-
deviceName | the name of the device |
void fesa::NotificationID::addProperty |
( |
const std::string & |
propertyName | ) |
|
|
inline |
This method adds a new class/property combination to be notified.
- Parameters
-
className | the name of the class to be notified |
propertyName | the name of the property to be notified |
bool fesa::NotificationID::contains |
( |
const std::string & |
propName, |
|
|
const std::string & |
deviceName |
|
) |
| const |
This method checks whether the notification ID contains the given combination of property and device.
- Parameters
-
propName | the name of the property |
deviceName | the name of the device |
- Returns
- true if the pair is contained, otherwise false
const std::set< std::string > & fesa::NotificationID::getDeviceCol |
( |
| ) |
const |
|
inline |
returns the set of devices corresponding to this NotificationID
- Returns
- const ref to the device collection
uint32_t fesa::NotificationID::getIDKey |
( |
| ) |
const |
|
inline |
returns the unique ID key, which identifies the notification ID and is the same for the server and the real-time side
- Returns
- the key
const std::set< std::string > & fesa::NotificationID::getNotifiedGlobalProperties |
( |
| ) |
const |
returns the set of global properties corresponding to this notification ID
- Returns
- const ref to the global property collection
const std::set< std::string > & fesa::NotificationID::getNotifiedPropertyCol |
( |
| ) |
const |
|
inline |
returns the set of properties corresponding to this notification ID
- Returns
- const ref to the property collection
The documentation for this class was generated from the following files:
- NotificationID.h
- NotificationID.cpp