|
nux-1.14.0
|
Scope Lock class. More...
#include <NuxCore/ThreadGNU.h>
Public Member Functions | |
| NScopeLock (NCriticalSection *CriticalSectionObject) | |
| The constructor locks the critical section object. | |
| ~NScopeLock (void) | |
Scope Lock class.
Takes a critical section object as parameter of the constructor. The constructor locks the critical section. The destructor unlocks the critical section.
Definition at line 126 of file ThreadGNU.h.
| nux::NScopeLock::NScopeLock | ( | NCriticalSection * | CriticalSectionObject | ) | [inline] |
The constructor locks the critical section object.
The constructor locks the critical section object.
| LockObject | Critical section object. |
Definition at line 134 of file ThreadGNU.h.
References nux::NCriticalSection::Lock().
: m_CriticalSectionObject (CriticalSectionObject)
{
nuxAssert (m_CriticalSectionObject);
m_CriticalSectionObject->Lock();
}
| nux::NScopeLock::~NScopeLock | ( | void | ) | [inline] |
The destructor unlocks the critical section object.
Definition at line 145 of file ThreadGNU.h.
References nux::NCriticalSection::Unlock().
{
nuxAssert (m_CriticalSectionObject);
m_CriticalSectionObject->Unlock();
}