#include <ncbimtx.hpp>
Collaboration diagram for SSystemMutex:

Define system mutex.
Internal platform-dependent mutex implementation to be used by CMutex and CFastMutex only.
Definition at line 382 of file ncbimtx.hpp.
Public Member Functions | |
| void | Lock (void) |
| Acquire mutex for the current thread. | |
| void | Unlock (void) |
| Release mutex. | |
| bool | TryLock (void) |
| Try to lock. | |
Static Public Member Functions | |
| static void | ThrowNotOwned (void) |
| Throw not owned("eOwner") exception. | |
Public Attributes | |
| SSystemFastMutex | m_Mutex |
| Mutex value. | |
| volatile CThreadSystemID | m_Owner |
| Platform-dependent owner thread ID. | |
| volatile int | m_Count |
| # of recursive (in the same thread) locks | |
Protected Member Functions | |
| bool | IsInitialized (void) const |
| Check if mutex is initialized. | |
| bool | IsUninitialized (void) const |
| Check if mutex is un-initialized. | |
| void | InitializeStatic (void) |
| Initialize static mutex. | |
| void | InitializeDynamic (void) |
| Initialize dynamic mutex. | |
| void | Destroy (void) |
| Destroy mutex. | |
Friends | |
| class | CAutoInitializeStaticMutex |
| class | CMutex |
|
|
Destroy mutex.
Definition at line 204 of file ncbimtx.cpp. References SSystemFastMutex::Destroy(), m_Count, m_Mutex, and xncbi_Validate. |
|
|
Initialize dynamic mutex. Initialize mutex if it located in heap or stack. This must be called only once. Do not count on zeroed memory values for initializing mutex values. |
|
|
Initialize static mutex. Must be called only once. |
|
|
Check if mutex is initialized.
|
|
|
Check if mutex is un-initialized.
|
|
|
Acquire mutex for the current thread.
Definition at line 295 of file ncbimtx.cpp. References SSystemFastMutex::CheckInitialized(), CThreadSystemID::GetCurrent(), CThreadSystemID::Is(), m_Count, m_Mutex, and m_Owner. |
|
|
Throw not owned("eOwner") exception.
Definition at line 358 of file ncbimtx.cpp. References NCBI_THROW. Referenced by Unlock(). |
|
|
Try to lock.
Definition at line 313 of file ncbimtx.cpp. References SSystemFastMutex::CheckInitialized(), CThreadSystemID::GetCurrent(), CThreadSystemID::Is(), m_Count, m_Mutex, and m_Owner. |
|
|
Release mutex.
Definition at line 336 of file ncbimtx.cpp. References SSystemFastMutex::CheckInitialized(), CThreadSystemID::GetCurrent(), CThreadSystemID::IsNot(), m_Count, m_Mutex, m_Owner, and ThrowNotOwned(). |
|
|
Definition at line 443 of file ncbimtx.hpp. |
|
|
Definition at line 444 of file ncbimtx.hpp. |
|
|
# of recursive (in the same thread) locks
Definition at line 388 of file ncbimtx.hpp. |
|
|
Mutex value.
Definition at line 384 of file ncbimtx.hpp. |
|
|
Platform-dependent owner thread ID.
Definition at line 386 of file ncbimtx.hpp. |
1.4.6
Modified on Mon Dec 07 16:24:33 2009 by modify_doxy.py rev. 173732