nn::os::LightEvent Class

Header file: nn/os.h

Syntax

class LightEvent

Description

Synchronization mechanism for communicating flags between threads.

The class has an internal flag that multiple threads can control in a safe manner. It can also be used to wait for the flag to be set.

The nn::os::LightEvent class is superior to the nn::os::Event class and should therefore be used in normal cases. Its only disadvantage is the fact that it is unable to wait for multiple synchronization objects simultaneously.

All member functions of this class are thread-safe except for the Initialize and Finalize functions.

Member Functions

Initialization/Finalization
LightEvent Constructor.
Initialize Performs initialization.
Finalize Performs finalization.
Obtaining Debug Info
IsSignaled Obtains whether the flag is set.
IsManualReset Determines whether an event is a manually resetting event.
Flag Operations and Blocking
TryWait Gets whether the flag is set.
Wait Waits until the flag is set.
Signal Sets the flag.
Pulse Deallocates threads that are waiting for the flag to be set.
ClearSignal Clears the flag.

Revision History

2010/06/14
Initial version.

CONFIDENTIAL