LCOV - code coverage report
Current view: top level - EMCAL/EMCALbase - AliEMCALTriggerDCSConfigDB.h (source / functions) Hit Total Coverage
Test: coverage.info Lines: 1 2 50.0 %
Date: 2016-06-14 17:26:59 Functions: 1 6 16.7 %

          Line data    Source code
       1             : #ifndef ALIEMCALTRIGGERDCSCONFIGDB_H
       2             : #define ALIEMCALTRIGGERDCSCONFIGDB_H
       3             : /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
       4             :  * See cxx source for full Copyright notice                               */
       5             : 
       6             : /*
       7             :  
       8             :  
       9             : 
      10             : Adapted from TRD: thanks!
      11             : Author: R. GUERNANE LPSC Grenoble CNRS/IN2P3
      12             : */
      13             : 
      14             : #ifndef ROOT_TObject
      15             : #include "TObject.h"
      16             : #endif
      17             : 
      18             : class AliCDBEntry;
      19             : 
      20             : class AliEMCALTriggerDCSConfig;
      21             : 
      22             : class AliEMCALTriggerDCSConfigDB : public TObject 
      23             : {
      24             : public:
      25             :         
      26             :         static AliEMCALTriggerDCSConfigDB*  Instance();
      27             :         static void                         Terminate();
      28             : 
      29             :         void                                SetRun(Long64_t run);
      30           0 :         Long64_t                            GetRun() const { return fRun; }
      31             :         const AliEMCALTriggerDCSConfig*     GetTriggerDCSConfig();
      32             :         
      33             : protected:
      34             : 
      35             :         // For caching see also implentation of GetCachedCDBObject in the .cxx file
      36             :         // For now, only one cached object but let the possibility to have more
      37             :         enum { kCDBCacheSize = 1    };   // Number of cached objects
      38             :         enum { kIDTriggerConfig = 0 };   // IDs of cached objects
      39             : 
      40             :         const TObject *GetCachedCDBObject(Int_t id);
      41             :   
      42             :         void           Invalidate();
      43             :     
      44             :         AliCDBEntry   *GetCDBEntry(const Char_t *cdbPath);
      45             :         const TObject *CacheCDBEntry(Int_t id, const Char_t *cdbPath);
      46             : 
      47             :         static AliEMCALTriggerDCSConfigDB* fgInstance;                 //  Instance of this class (singleton implementation)
      48             :         static Bool_t                      fgTerminated;               //  Defines if this class has already been terminated
      49             : 
      50             :         AliCDBEntry*                       fCDBEntries[kCDBCacheSize]; //  Cache for CDB entries
      51             :         TObject*                           fCDBCache[kCDBCacheSize];   //  Cache for calibration objects.
      52             : 
      53             :         Long64_t                           fRun;                       //  Run Number
      54             :   
      55             :  private:
      56             : 
      57             :         AliEMCALTriggerDCSConfigDB();                                  //  This is a singleton, constructor is private!  
      58             :         AliEMCALTriggerDCSConfigDB(const AliEMCALTriggerDCSConfigDB &c);   
      59             :         AliEMCALTriggerDCSConfigDB &operator=(const AliEMCALTriggerDCSConfigDB &c); 
      60             :         virtual ~AliEMCALTriggerDCSConfigDB();
      61             : 
      62          42 :         ClassDef(AliEMCALTriggerDCSConfigDB, 1)                         //  Provides central access to the CDB
      63             : };
      64             : 
      65             : #endif
      66             : 

Generated by: LCOV version 1.11