DUNE: Uniform Navigational Environment  2019.02.0
DUNE::Concurrency::ScopedRWLock Class Reference

Detailed Description

Scoped Read/Write lock.

Public Member Functions

 ScopedRWLock (RWLock &l, bool write=false)
 
 ~ScopedRWLock (void)
 

Constructor & Destructor Documentation

DUNE::Concurrency::ScopedRWLock::ScopedRWLock ( RWLock l,
bool  write = false 
)
inline

Construct the object, locking the associated read/write lock.

Parameters
lassociated lock.
writetrue to perform a write lock, false to perform a read lock.

References DUNE::Concurrency::RWLock::lockRead(), and DUNE::Concurrency::RWLock::lockWrite().

DUNE::Concurrency::ScopedRWLock::~ScopedRWLock ( void  )
inline

Destruct the object, unlocking the associated read/write lock.

References DUNE::Concurrency::RWLock::unlock().

Collaboration diagram for DUNE::Concurrency::ScopedRWLock:
Collaboration graph