ScopedReadWriteLock.h++ File Reference

#include <commonc++/Common.h++>
#include <commonc++/ReadWriteLock.h++>
Include dependency graph for ScopedReadWriteLock.h++:

Go to the source code of this file.

Classes

class  ScopedReadLock
 A convenience object for lexical scope based synchronization. More...
class  ScopedWriteLock
 A convenience object for lexical scope based synchronization. More...

Namespaces

namespace  ccxx

Defines

#define synchronized_read(LOCK)
 Introduce a code block that is read-locked by the ReadWriteLock LOCK.
#define synchronized_write(LOCK)
 Introduce a code block that is write-locked by the ReadWriteLock LOCK.

Define Documentation

#define synchronized_read ( LOCK   ) 
Value:
for(commoncpp::ScopedReadLock                                         \
        CCXX_OS_UNIQUE_VARNAME(LOCK, __LINE__, locker)(LOCK);           \
      CCXX_OS_UNIQUE_VARNAME(LOCK, __LINE__, locker).testOnce();)

Introduce a code block that is read-locked by the ReadWriteLock LOCK.

#define synchronized_write ( LOCK   ) 
Value:
for(commoncpp::ScopedWriteLock                                        \
        CCXX_OS_UNIQUE_VARNAME(LOCK, __LINE__, locker)(LOCK);           \
      CCXX_OS_UNIQUE_VARNAME(LOCK, __LINE__, locker).testOnce();)

Introduce a code block that is write-locked by the ReadWriteLock LOCK.

Generated on Sat Nov 26 16:49:08 2011 for libcommonc++ by  doxygen 1.6.3