LogCabin
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines
Public Member Functions | Public Attributes | Private Member Functions
LogCabin::Event::Loop::Lock Class Reference

Lock objects are used to synchronize between the Event::Loop thread and other threads. More...

#include <Loop.h>

List of all members.

Public Member Functions

 Lock (Event::Loop &eventLoop)
 Constructor. Acquire the lock.
 ~Lock ()
 Destructor. Release the lock.

Public Attributes

Event::LoopeventLoop
 Event::Loop to lock.

Private Member Functions

 Lock (const Lock &)
Lockoperator= (const Lock &)

Detailed Description

Lock objects are used to synchronize between the Event::Loop thread and other threads.

As long as a Lock object exists the following guarantees are in effect: either (a) the thread is the event loop thread or (b) no other thread has a Lock object and the event loop thread has paused in a safe place (with no event handlers active) waiting for the Lock to be destroyed. Locks may be used recursively.

Definition at line 51 of file Loop.h.


Constructor & Destructor Documentation

LogCabin::Event::Loop::Lock::Lock ( Event::Loop eventLoop) [explicit]

Constructor. Acquire the lock.

Definition at line 48 of file Loop.cc.

Destructor. Release the lock.

Definition at line 72 of file Loop.cc.

LogCabin::Event::Loop::Lock::Lock ( const Lock ) [private]

Member Function Documentation

Lock& LogCabin::Event::Loop::Lock::operator= ( const Lock ) [private]

Member Data Documentation

Event::Loop to lock.

Definition at line 58 of file Loop.h.


The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines