8#include "Arp/System/Commons/Logging.h"
9#include "Arp/Plc/Commons/Esm/RtEventManagerSharedData.hpp"
10#include "boost/interprocess/sync/interprocess_semaphore.hpp"
13namespace Arp {
namespace Plc {
namespace Commons {
namespace Esm
61 bool WaitOne(
unsigned long timeout = 0,
bool setSubscriberReady =
true);
70 boost::interprocess::interprocess_semaphore semaphore1;
71 boost::interprocess::interprocess_semaphore semaphore2;
72 std::atomic<bool> isSubscriberReady;
85 this->isSubscriberReady = isSubscriberReadyArg;
90 return this->isSubscriberReady;
Rt event for bidirectional exchange of events in the ESM context. E.g. this is used to trigger a task...
Definition: RtEvent.hpp:22
bool WaitOne(unsigned long timeout=0, bool setSubscriberReady=true)
Waits blocking on the signal of the sender.
String GetName()
Returns the identifier of the rt event.
Definition: RtEvent.hpp:78
RtEvent & operator=(const RtEvent &arg)=delete
Assignment operator.
RtEvent(const RtEvent &arg)=delete
Copy constructor.
RtEvent(const String &nameArg)
Constructs an RtEvent instance.
bool IsSubscriberReady(void)
Returns state of the subscriber to processing incoming signaled events.
Definition: RtEvent.hpp:88
RtEvent(const String &nameArg, uint32 value)
Constructs an RtEvent instance. - For internal use only!
bool SetAndWaitOne(unsigned long timeout=0)
Signals the event to the subscriber and waits blocking on the done by the subscriber.
void Set(void)
Signals the event to the subscriber.
RtEventManagerSharedData::Ptr< RtEvent > Ptr
Shared pointer type of RtEvent.
Definition: RtEvent.hpp:25
void Done(void)
Signals that the event was processed by the subscriber to the sender.
~RtEvent(void)=default
Destructs this instance and frees all resources.
void SetSubscriberReady(bool isSubscriberReadyArg)
Sets the state of the subscriber to processing incoming signaled events.
Definition: RtEvent.hpp:83
Definition: Loggable.hxx:20
boost::interprocess::offset_ptr< T > Ptr
Returned pointer types are shared memory based offset pointer.
Definition: SharedMemory.hpp:25
std::uint32_t uint32
The Arp unsigned integer type of 4 byte size.
Definition: PrimitiveTypes.hpp:36
Root namespace for the PLCnext API