Library: Foundation
Package: Processes
Header: Poco/NamedEvent.h
An NamedEvent is a global synchronization object that allows one process or thread to signal an other process or thread that a certain event has happened.
Unlike an Event, which itself is the unit of synchronization, a NamedEvent refers to a named operating system resource being the unit of synchronization. In other words, there can be multiple instances of NamedEvent referring to the same actual synchronization object.
NamedEvents are always autoresetting.
There should not be more than one instance of NamedEvent for a given name in a process. Otherwise, the instances may interfere with each other.
Direct Base Classes: NamedEventImpl
All Base Classes: NamedEventImpl
NamedEvent(
const std::string & name
);
Creates the event.
~NamedEvent();
Destroys the event.
void set();
Signals the event. The one thread or process waiting for the event can resume execution.
void wait();
Waits for the event to become signalled.