|
||||
File indexing completed on 2025-01-18 10:12:20
0001 // @(#)root/thread:$Id$ 0002 // Author: Fons Rademakers 01/07/97 0003 0004 /************************************************************************* 0005 * Copyright (C) 1995-2000, Rene Brun and Fons Rademakers. * 0006 * All rights reserved. * 0007 * * 0008 * For the licensing terms see $ROOTSYS/LICENSE. * 0009 * For the list of contributors see $ROOTSYS/README/CREDITS. * 0010 *************************************************************************/ 0011 0012 #ifndef ROOT_TPosixCondition 0013 #define ROOT_TPosixCondition 0014 0015 0016 ////////////////////////////////////////////////////////////////////////// 0017 // // 0018 // TPosixCondition // 0019 // // 0020 // This class provides an interface to the posix condition variable // 0021 // routines. // 0022 // // 0023 ////////////////////////////////////////////////////////////////////////// 0024 0025 #include "TConditionImp.h" 0026 0027 #include <pthread.h> 0028 0029 class TMutexImp; 0030 class TPosixMutex; 0031 0032 0033 class TPosixCondition : public TConditionImp { 0034 0035 private: 0036 pthread_cond_t fCond; // the pthread condition variable 0037 TPosixMutex *fMutex; // mutex used around Wait() and TimedWait() 0038 0039 public: 0040 TPosixCondition(TMutexImp *m); 0041 virtual ~TPosixCondition(); 0042 0043 Int_t Wait() override; 0044 Int_t TimedWait(ULong_t secs, ULong_t nanoSecs = 0) override; 0045 Int_t Signal() override; 0046 Int_t Broadcast() override; 0047 0048 ClassDefOverride(TPosixCondition,0) // Posix condition variable 0049 }; 0050 0051 #endif
[ Source navigation ] | [ Diff markup ] | [ Identifier search ] | [ general search ] |
This page was automatically generated by the 2.3.7 LXR engine. The LXR team |