1#ifndef COIN_SBRWMUTEX_H
2#define COIN_SBRWMUTEX_H
27#include <Inventor/C/threads/rwmutex.h>
37 this->rwmutex = cc_rwmutex_construct_etc(
38 (policy == WRITE_PRECEDENCE)? CC_WRITE_PRECEDENCE : CC_READ_PRECEDENCE);
43 return cc_rwmutex_write_lock(this->rwmutex) == CC_OK ? 0 : 1;
46 return cc_rwmutex_write_try_lock(this->rwmutex) == CC_OK;
49 return cc_rwmutex_write_unlock(this->rwmutex) == CC_OK ? 0 : 1;
53 return cc_rwmutex_read_lock(this->rwmutex) == CC_OK ? 0 : 1;
56 return cc_rwmutex_read_try_lock(this->rwmutex) == CC_OK;
59 return cc_rwmutex_read_unlock(this->rwmutex) == CC_OK ? 0 : 1;
Definition SbRWMutex.h:29
SbRWMutex(Precedence policy)
Definition SbRWMutex.h:36
int writeLock(void)
Definition SbRWMutex.h:42
int writeUnlock(void)
Definition SbRWMutex.h:48
int tryReadLock(void)
Definition SbRWMutex.h:55
SbBool tryWriteLock(void)
Definition SbRWMutex.h:45
int readLock(void)
Definition SbRWMutex.h:52
~SbRWMutex(void)
Definition SbRWMutex.h:40
int readUnlock(void)
Definition SbRWMutex.h:58
Copyright © 1998-2010 by Kongsberg Oil & Gas Technologies. All rights reserved.
Generated on Wed Jul 17 2024 for Coin by Doxygen 1.12.0.