/search.css" rel="stylesheet" type="text/css"/> /search.js">
00001 // $Id: DbiTimerManager.h,v 1.2 2003/03/25 07:59:32 west Exp $ 00002 00003 #ifndef DBITIMERMANAGER 00004 #define DBITIMERMANAGER 00005 00007 // DbiTimerManager // 00008 // // 00009 // Package: Dbi (Database Interface). // 00010 // // 00011 // N. West 01/2002 // 00012 // // 00013 // Concept: Manager of a set of simple timers. // 00014 // // 00015 // Purpose: To find out why this is all soooo sssllloooowwww! // 00016 // // 00018 00019 #include <string> 00020 #include <list> 00021 #include <Rtypes.h> 00022 00023 using std::string; 00024 using std::list; 00025 00026 class DbiTableMetaData; 00027 class DbiTimer; 00028 00029 class DbiTimerManager 00030 { 00031 00032 public: 00033 00034 // Constructors and destructors. 00035 DbiTimerManager(); 00036 virtual ~DbiTimerManager(); 00037 00038 // State testing member functions 00039 00040 // State changing member functions 00041 void Enable(Bool_t flag=kTRUE, 00042 Bool_t enableSubWatch = kFALSE) { fEnabled = flag; 00043 fSubWatchEnabled = enableSubWatch;} 00044 void RecBegin(string tableName, UInt_t rowSize); 00045 void RecEnd(UInt_t numRows); 00046 void RecFillAgg(Int_t aggNo); 00047 void RecMainQuery(); 00048 void StartSubWatch(UInt_t subWatch); 00049 00050 // Global timer manager used for all queries to the DBI. 00051 00052 static DbiTimerManager gTimerManager; 00053 00054 private: 00055 00056 DbiTimer* GetCurrent(); 00057 DbiTimer* Pop(); 00058 DbiTimer* Push(); 00059 00060 // Data members 00061 00062 Bool_t fEnabled; // Enable/disable 00063 Bool_t fSubWatchEnabled; 00064 // SubWatch Enable/disable (not used now). 00065 list<DbiTimer*> fTimers; // Push-down stack of timers. 00066 00067 // Removed: ClassDef(DbiTimerManager,0) // Simple query timer 00068 00069 }; 00070 00071 00072 #endif // DBITIMERMANAGER 00073