NotificationInfo holds the state of a trigger like the pointer to the triggerOrigin, the notification id and the callback.
More...
#include <iceoryx_posh/popo/notification_info.hpp>
NotificationInfo holds the state of a trigger like the pointer to the triggerOrigin, the notification id and the callback.
◆ NotificationInfo()
constructs a NotificationInfo object
- Parameters
-
[in] | notificationOrigin | the origin of the event |
[in] | notificationId | id of the event |
[in] | callback | the callback of the event |
◆ doesOriginateFrom()
bool iox::popo::NotificationInfo::doesOriginateFrom |
( |
T *const |
notificationOrigin | ) |
const |
|
noexcept |
confirms the notificationOrigin
- Parameters
-
[in] | notificationOrigin | the possible notificationOrigin |
- Returns
- true if the address is equal to the notificationOrigin, otherwise false. The empty NotificationInfo returns always false.
◆ getNotificationId()
uint64_t iox::popo::NotificationInfo::getNotificationId |
( |
| ) |
const |
|
noexcept |
returns the notification id
- Returns
- the empty NotificationInfo always returns INVALID_ID, otherwise the actual notificationId is returned which can also be INVALID_ID
◆ getOrigin()
T * iox::popo::NotificationInfo::getOrigin |
( |
| ) |
const |
|
noexcept |
returns the pointer to the notificationOrigin.
- Returns
- If T equals the Triggerable type it returns the notificationOrigin. Otherwise it calls the errorHandler with a moderate error of kPOPO__EVENT_INFO_TYPE_INCONSISTENCY_IN_GET_ORIGIN and returns nullptr.
◆ operator()()
bool iox::popo::NotificationInfo::operator() |
( |
| ) |
const |
|
noexcept |
If a callback is set it executes the callback.
- Returns
- true if the callback was called, otherwise false
The documentation for this class was generated from the following file: