NAME
ACE_rwlock_t
SYNOPSIS
#include <ace/OS.h>
struct ACE_rwlock_t
{
public:
ACE_mutex_t lock_;
ACE_cond_t waiting_readers_;
int num_waiting_readers_;
ACE_cond_t waiting_writers_;
int num_waiting_writers_;
int ref_count_;
ACE_mutex_t lock_;
ACE_cond_t waiting_readers_;
int num_waiting_readers_;
ACE_cond_t waiting_writers_;
int num_waiting_writers_;
int ref_count_;
};
DESCRIPTION
At the current time, this stuff only works for threads
within the same process.
PUBLIC MEMBERS
ACE_mutex_t lock_;
Serialize access to internal state.
ACE_cond_t waiting_readers_;
Reader threads waiting to acquire the lock.
int num_waiting_readers_;
Number of waiting readers.
ACE_cond_t waiting_writers_;
Writer threads waiting to acquire the lock.
int num_waiting_writers_;
Number of waiting writers.
int ref_count_;
Value is -1 if writer has the lock, else this keeps track of the
number of readers holding the lock.
ACE_mutex_t lock_;
Serialize access to internal state.
ACE_cond_t waiting_readers_;
Reader threads waiting to acquire the lock.
int num_waiting_readers_;
Number of waiting readers.
ACE_cond_t waiting_writers_;
Writer threads waiting to acquire the lock.
int num_waiting_writers_;
Number of waiting writers.
int ref_count_;
Value is -1 if writer has the lock, else this keeps track of the
number of readers holding the lock.
AUTHOR
Doug Schmidt schmidt@cs.wustl.edu, Jesper S. M|ller
stophph@diku.dk, and a cast of thousands...
TITLE
This is used to implement readers/writer locks on NT.
LIBRARY
ace