F´ Flight Software - C/C++ Documentation
devel
A framework for building embedded system applications to NASA flight quality standards.
|
condition variable implementation More...
#include <Os/Condition.hpp>
Public Member Functions | |
ConditionVariable () | |
default constructor More... | |
~ConditionVariable () final | |
default virtual destructor More... | |
ConditionVariable (const ConditionVariableInterface &other)=delete | |
copy constructor is forbidden More... | |
ConditionVariable (const ConditionVariableInterface *other)=delete | |
copy constructor is forbidden More... | |
ConditionVariableInterface & | operator= (const ConditionVariableInterface &other) override=delete |
assignment operator is forbidden More... | |
void | wait (Os::Mutex &mutex) override |
wait on a condition variable More... | |
void | notify () override |
notify a single waiter on this condition variable More... | |
void | notifyAll () override |
notify all waiters on this condition variable More... | |
ConditionVariableHandle * | getHandle () override |
return the underlying condition variable handle (implementation specific). Delegates to implementation. More... | |
Public Member Functions inherited from Os::ConditionVariableInterface | |
ConditionVariableInterface ()=default | |
Default constructor. More... | |
virtual | ~ConditionVariableInterface ()=default |
Default destructor. More... | |
ConditionVariableInterface (const ConditionVariableInterface &other)=delete | |
copy constructor is forbidden More... | |
Additional Inherited Members | |
Static Public Member Functions inherited from Os::ConditionVariableInterface | |
static ConditionVariableInterface * | getDelegate (ConditionVariableHandleStorage &aligned_new_memory) |
provide a pointer to a Mutex delegate object More... | |
condition variable implementation
Condition variables allow a program to block on a condition while atomically releasing an Os::Mutex and atomically reacquiring the mutex once the condition has been notified.
Definition at line 66 of file Condition.hpp.
Os::ConditionVariable::ConditionVariable | ( | ) |
default constructor
Definition at line 5 of file Condition.cpp.
|
final |
default virtual destructor
Definition at line 7 of file Condition.cpp.
|
delete |
copy constructor is forbidden
|
delete |
copy constructor is forbidden
|
overridevirtual |
return the underlying condition variable handle (implementation specific). Delegates to implementation.
Implements Os::ConditionVariableInterface.
Definition at line 29 of file Condition.cpp.
|
overridevirtual |
notify a single waiter on this condition variable
Notify a single waiter on this condition variable. It is not necessary to hold the mutex supplied by the waiters and it is advantageous not to hold the lock to prevent immediate re-blocking. This function delegates to the underlying implementation.
Implements Os::ConditionVariableInterface.
Definition at line 20 of file Condition.cpp.
|
overridevirtual |
notify all waiters on this condition variable
Notify all waiters on this condition variable. It is not necessary to hold the mutex supplied by the waiters and it is advantageous not to hold the lock to prevent immediate re-blocking. This function delegates to the underlying implementation.
Implements Os::ConditionVariableInterface.
Definition at line 24 of file Condition.cpp.
|
overridevirtualdelete |
assignment operator is forbidden
Reimplemented from Os::ConditionVariableInterface.
|
overridevirtual |
wait on a condition variable
Wait on a condition variable. This function will atomically unlock the provided mutex and block on the condition in one step. Blocking will occur until a future notify
or notifyAll
call is made to this variable on another thread of execution. This function delegates to the underlying implementation.
mutex | mutex to unlock as part of this operation |
Implements Os::ConditionVariableInterface.
Definition at line 11 of file Condition.cpp.