ldas-tools-al
2.6.6
|
Implements read/write lock symantics for a variable. More...
#include <ReadWriteLock.hh>
Public Types | |
typedef ReadWriteLock::baton_type | baton_type |
Baton. More... | |
typedef V | element_type |
Type of variable. More... | |
typedef ReadWriteLock::baton_type | baton_type |
Baton. More... | |
typedef V | element_type |
Type of variable. More... | |
typedef ReadWriteLock::baton_type | baton_type |
Baton. More... | |
typedef V | element_type |
Type of variable. More... | |
Public Member Functions | |
ReadWriteLockVariable (baton_type Baton, int Timeout, V &Variable, const char *Filename, int Linenum) | |
Constructor. More... | |
ReadWriteLockVariable (baton_type Baton, int Timeout, const V &Variable, const char *Filename, int Linenum) | |
Constructor. More... | |
ReadWriteLockVariable (const ReadWriteLockVariable &Source, const char *Filename, int Linenum) | |
Copy constructor. More... | |
const V & | Var () const |
Read only access to the variable. More... | |
V & | Var () |
Read/Write access to the variable. More... | |
ReadWriteLockVariable (baton_type Baton, int Timeout, V &Variable, const char *Filename, int Linenum) | |
Constructor. More... | |
ReadWriteLockVariable (baton_type Baton, int Timeout, const V &Variable, const char *Filename, int Linenum) | |
Constructor. More... | |
ReadWriteLockVariable (const ReadWriteLockVariable &Source, const char *Filename, int Linenum) | |
Copy constructor. More... | |
const V & | Var () const |
Read only access to the variable. More... | |
V & | Var () |
Read/Write access to the variable. More... | |
ReadWriteLockVariable (baton_type Baton, int Timeout, V &Variable, const char *Filename, int Linenum) | |
Constructor. More... | |
ReadWriteLockVariable (baton_type Baton, int Timeout, const V &Variable, const char *Filename, int Linenum) | |
Constructor. More... | |
ReadWriteLockVariable (const ReadWriteLockVariable &Source, const char *Filename, int Linenum) | |
Copy constructor. More... | |
const V & | Var () const |
Read only access to the variable. More... | |
V & | Var () |
Read/Write access to the variable. More... | |
Private Member Functions | |
ReadWriteLockVariable () | |
baton_type | release (const char *File, int Line) const |
ReadWriteLockVariable () | |
baton_type | release (const char *File, int Line) const |
ReadWriteLockVariable () | |
baton_type | release (const char *File, int Line) const |
Private Attributes | |
baton_type | m_baton |
int | m_timeout |
V & | m_variable |
ReadWriteLock | m_lock |
bool | m_is_locked |
const bool | m_is_read_only |
Implements read/write lock symantics for a variable.
This class allows for manipulation of variables to be thread safe.
typedef ReadWriteLock::baton_type LDASTools::AL::ReadWriteLockVariable< T, V >::baton_type |
Baton.
The resource used to manage resouce access.
typedef ReadWriteLock::baton_type LDASTools::AL::ReadWriteLockVariable< T, V >::baton_type |
Baton.
The resource used to manage resouce access.
typedef ReadWriteLock::baton_type LDASTools::AL::ReadWriteLockVariable< T, V >::baton_type |
Baton.
The resource used to manage resouce access.
typedef V LDASTools::AL::ReadWriteLockVariable< T, V >::element_type |
Type of variable.
The type of variable being managed.
typedef V LDASTools::AL::ReadWriteLockVariable< T, V >::element_type |
Type of variable.
The type of variable being managed.
typedef V LDASTools::AL::ReadWriteLockVariable< T, V >::element_type |
Type of variable.
The type of variable being managed.
|
inline |
Constructor.
[in] | Baton | Baton controlling access to the resource. |
[in] | Timeout | Maximum length of time to wait on obtaining the lock. |
[in] | Variable | Variable being managed by the class. |
[in] | Filename | The filename from where the call was made. |
[in] | Linenum | The line number from where the call was made. |
|
inline |
Constructor.
[in] | Baton | Baton controlling access to the resource. |
[in] | Timeout | Maximum length of time to wait on obtaining the lock. |
[in] | Variable | Variable being managed by the class. |
[in] | Filename | The filename from where the call was made. |
[in] | Linenum | The line number from where the call was made. |
|
inline |
Copy constructor.
[in] | Source | Source from which to initialize. |
[in] | Filename | The filename from where the call was made. |
[in] | Linenum | The line number from where the call was made. |
|
private |
LDASTools::AL::ReadWriteLockVariable< T, V >::ReadWriteLockVariable | ( | baton_type | Baton, |
int | Timeout, | ||
V & | Variable, | ||
const char * | Filename, | ||
int | Linenum | ||
) |
Constructor.
[in] | Baton | Baton controlling access to the resource. |
[in] | Timeout | Maximum length of time to wait on obtaining the lock. |
[in] | Variable | Variable being managed by the class. |
[in] | Filename | The filename from where the call was made. |
[in] | Linenum | The line number from where the call was made. |
LDASTools::AL::ReadWriteLockVariable< T, V >::ReadWriteLockVariable | ( | baton_type | Baton, |
int | Timeout, | ||
const V & | Variable, | ||
const char * | Filename, | ||
int | Linenum | ||
) |
Constructor.
[in] | Baton | Baton controlling access to the resource. |
[in] | Timeout | Maximum length of time to wait on obtaining the lock. |
[in] | Variable | Variable being managed by the class. |
[in] | Filename | The filename from where the call was made. |
[in] | Linenum | The line number from where the call was made. |
LDASTools::AL::ReadWriteLockVariable< T, V >::ReadWriteLockVariable | ( | const ReadWriteLockVariable< T, V > & | Source, |
const char * | Filename, | ||
int | Linenum | ||
) |
Copy constructor.
[in] | Source | Source from which to initialize. |
[in] | Filename | The filename from where the call was made. |
[in] | Linenum | The line number from where the call was made. |
|
private |
LDASTools::AL::ReadWriteLockVariable< T, V >::ReadWriteLockVariable | ( | baton_type | Baton, |
int | Timeout, | ||
V & | Variable, | ||
const char * | Filename, | ||
int | Linenum | ||
) |
Constructor.
[in] | Baton | Baton controlling access to the resource. |
[in] | Timeout | Maximum length of time to wait on obtaining the lock. |
[in] | Variable | Variable being managed by the class. |
[in] | Filename | The filename from where the call was made. |
[in] | Linenum | The line number from where the call was made. |
LDASTools::AL::ReadWriteLockVariable< T, V >::ReadWriteLockVariable | ( | baton_type | Baton, |
int | Timeout, | ||
const V & | Variable, | ||
const char * | Filename, | ||
int | Linenum | ||
) |
Constructor.
[in] | Baton | Baton controlling access to the resource. |
[in] | Timeout | Maximum length of time to wait on obtaining the lock. |
[in] | Variable | Variable being managed by the class. |
[in] | Filename | The filename from where the call was made. |
[in] | Linenum | The line number from where the call was made. |
LDASTools::AL::ReadWriteLockVariable< T, V >::ReadWriteLockVariable | ( | const ReadWriteLockVariable< T, V > & | Source, |
const char * | Filename, | ||
int | Linenum | ||
) |
Copy constructor.
[in] | Source | Source from which to initialize. |
[in] | Filename | The filename from where the call was made. |
[in] | Linenum | The line number from where the call was made. |
|
private |
|
inlineprivate |
|
inlineprivate |
|
inlineprivate |
const V& LDASTools::AL::ReadWriteLockVariable< T, V >::Var | ( | ) | const |
Read only access to the variable.
const V& LDASTools::AL::ReadWriteLockVariable< T, V >::Var | ( | ) | const |
Read only access to the variable.
|
inline |
Read only access to the variable.
|
inline |
Read/Write access to the variable.
V& LDASTools::AL::ReadWriteLockVariable< T, V >::Var | ( | ) |
Read/Write access to the variable.
V& LDASTools::AL::ReadWriteLockVariable< T, V >::Var | ( | ) |
Read/Write access to the variable.
|
private |
|
mutableprivate |
|
private |
|
mutableprivate |
|
private |
|
private |