libMesh::Threads::spin_mutex::scoped_lock Class Reference

#include <threads.h>

Public Member Functions

 scoped_lock ()
 
 scoped_lock (spin_mutex &in_smutex)
 
 ~scoped_lock ()
 
void acquire (spin_mutex &in_smutex)
 
void release ()
 
 scoped_lock ()
 
 scoped_lock (spin_mutex &in_smutex)
 
 ~scoped_lock ()
 
void acquire (spin_mutex &in_smutex)
 
void release ()
 
 scoped_lock ()
 
 scoped_lock (spin_mutex &)
 
void acquire (spin_mutex &)
 
void release ()
 

Private Attributes

spin_mutexsmutex
 

Detailed Description

Definition at line 343 of file threads.h.

Constructor & Destructor Documentation

libMesh::Threads::spin_mutex::scoped_lock::scoped_lock ( )
inline

Definition at line 346 of file threads.h.

References smutex.

346 : smutex(NULL) {}
libMesh::Threads::spin_mutex::scoped_lock::scoped_lock ( spin_mutex in_smutex)
inlineexplicit

Definition at line 347 of file threads.h.

References libMesh::Threads::spin_mutex::lock(), and smutex.

347 : smutex(&in_smutex) { smutex->lock(); }
libMesh::Threads::spin_mutex::scoped_lock::~scoped_lock ( )
inline

Definition at line 349 of file threads.h.

References release().

349 { release(); }
libMesh::Threads::spin_mutex::scoped_lock::scoped_lock ( )
inline

Definition at line 375 of file threads.h.

References smutex.

375 : smutex(NULL) {}
libMesh::Threads::spin_mutex::scoped_lock::scoped_lock ( spin_mutex in_smutex)
inlineexplicit

Definition at line 376 of file threads.h.

References libMesh::Threads::spin_mutex::lock(), and smutex.

376 : smutex(&in_smutex) { smutex->lock(); }
libMesh::Threads::spin_mutex::scoped_lock::~scoped_lock ( )
inline

Definition at line 378 of file threads.h.

References release().

378 { release(); }
libMesh::Threads::spin_mutex::scoped_lock::scoped_lock ( )
inline

Definition at line 856 of file threads.h.

856 {}
libMesh::Threads::spin_mutex::scoped_lock::scoped_lock ( spin_mutex )
inlineexplicit

Definition at line 857 of file threads.h.

857 {}

Member Function Documentation

void libMesh::Threads::spin_mutex::scoped_lock::acquire ( spin_mutex in_smutex)
inline

Definition at line 351 of file threads.h.

References libMesh::Threads::spin_mutex::lock(), and smutex.

351 { smutex = &in_smutex; smutex->lock(); }
void libMesh::Threads::spin_mutex::scoped_lock::acquire ( spin_mutex in_smutex)
inline

Definition at line 380 of file threads.h.

References libMesh::Threads::spin_mutex::lock(), and smutex.

380 { smutex = &in_smutex; smutex->lock(); }
void libMesh::Threads::spin_mutex::scoped_lock::acquire ( spin_mutex )
inline

Definition at line 858 of file threads.h.

858 {}
void libMesh::Threads::spin_mutex::scoped_lock::release ( )
inline

Definition at line 352 of file threads.h.

References smutex, and libMesh::Threads::spin_mutex::unlock().

Referenced by ~scoped_lock().

352 { if(smutex) smutex->unlock(); smutex = NULL; }
void libMesh::Threads::spin_mutex::scoped_lock::release ( )
inline

Definition at line 381 of file threads.h.

References smutex, and libMesh::Threads::spin_mutex::unlock().

381 { if(smutex) smutex->unlock(); smutex = NULL; }
void libMesh::Threads::spin_mutex::scoped_lock::release ( )
inline

Definition at line 859 of file threads.h.

859 {}

Member Data Documentation

spin_mutex * libMesh::Threads::spin_mutex::scoped_lock::smutex
private

Definition at line 355 of file threads.h.

Referenced by acquire(), release(), and scoped_lock().


The documentation for this class was generated from the following file:

Site Created By: libMesh Developers
Last modified: February 07 2014 16:57:33 UTC

Hosted By:
SourceForge.net Logo