]> git.uio.no Git - u/mrichter/AliRoot.git/blame - MUON/AliMUONCalibrationData.h
small fix
[u/mrichter/AliRoot.git] / MUON / AliMUONCalibrationData.h
CommitLineData
c5bdf179 1/* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
2* See cxx source for full Copyright notice */
3
4// $Id$
5
6/// \ingroup base
7/// \class AliMUONCalibrationData
c3ce65fd 8/// \brief Single entry point to access MUON calibration data.
9///
10/// For the moment, this class stores pedestals, gains and deadchannels
11/// that are fetched from the CDB.
c5bdf179 12///
13/// \author Laurent Aphecetche
14
15#ifndef ALIMUONCALIBRATIONDATA_H
16#define ALIMUONCALIBRATIONDATA_H
17
18#ifndef ROOT_TObject
19#include "TObject.h"
20#endif
21
22class AliCDBEntry;
e7d7fa47 23class AliMUONTriggerEfficiencyCells;
24class AliMUONTriggerLut;
25class AliMUONV1DStore;
c3ce65fd 26class AliMUONV2DStore;
e7d7fa47 27class AliMUONVCalibParam;
c5bdf179 28
29class AliMUONCalibrationData : public TObject
30{
31public:
c3ce65fd 32 /** Constructor.
33 * @param runNumber is used as a key to the CDB
34 * @param deferredInitialization if kFALSE, all the calibrations are fetched
35 * regardless of whether you'll use them or not.
36 */
c5bdf179 37 AliMUONCalibrationData(Int_t runNumber=-1, Bool_t deferredInitialization=kTRUE);
38 virtual ~AliMUONCalibrationData();
c3ce65fd 39
40 /// Get the DeadChannel calibration object for channels within (detElemId,manuId).
e7d7fa47 41 AliMUONVCalibParam* DeadChannels(Int_t detElemId, Int_t manuId) const;
c5bdf179 42
c3ce65fd 43 /// Get the Gain calibration object for channels within (detElemId,manuId).
e7d7fa47 44 AliMUONVCalibParam* Gains(Int_t detElemId, Int_t manuId) const;
45
46 /// Get the mask for the global trigger board.
47 AliMUONVCalibParam* GlobalTriggerBoardMasks() const;
c3ce65fd 48
e7d7fa47 49 /// Get the mask for a given local trigger board.
50 AliMUONVCalibParam* LocalTriggerBoardMasks(Int_t localBoardNumber) const;
51
c3ce65fd 52 /// Whether this object is valid or not (might be invalid if fetching from CDB failed).
53 Bool_t IsValid() const { return fIsValid; }
c5bdf179 54
c3ce65fd 55 /// Get the Pedestal calibration object for channels within (detElemId,manuId).
e7d7fa47 56 AliMUONVCalibParam* Pedestals(Int_t detElemId, Int_t manuId) const;
c5bdf179 57
c3ce65fd 58 /// Dump to screen.
c5bdf179 59 virtual void Print(Option_t* opt="") const;
e7d7fa47 60
61 /// Get the mask for a given regional trigger board.
62 AliMUONVCalibParam* RegionalTriggerBoardMasks(Int_t index) const;
63
c3ce65fd 64 /// The runnumber used by this object.
65 Int_t RunNumber() const { return fRunNumber; }
c5bdf179 66
e7d7fa47 67 /// Get the trigger Look Up Table.
68 AliMUONTriggerLut* TriggerLut() const;
69
70 /// Get the trigger efficiency map
71 AliMUONTriggerEfficiencyCells* TriggerEfficiency() const;
72
884a73f1 73protected:
e7d7fa47 74 AliMUONCalibrationData(const AliMUONCalibrationData& other);
75 AliMUONCalibrationData& operator=(const AliMUONCalibrationData& other);
76
c5bdf179 77private:
78 AliCDBEntry* GetEntry(const char* path) const;
e7d7fa47 79 AliMUONV2DStore* OnDemandGains() const;
80 AliMUONV2DStore* OnDemandPedestals() const;
81 AliMUONV2DStore* OnDemandDeadChannels() const;
82 AliMUONVCalibParam* OnDemandGlobalTriggerBoardMasks() const;
83 AliMUONV1DStore* OnDemandRegionalTriggerBoardMasks() const;
84 AliMUONV1DStore* OnDemandLocalTriggerBoardMasks() const;
85 AliMUONTriggerLut* OnDemandTriggerLut() const;
86 AliMUONTriggerEfficiencyCells* OnDemandTriggerEfficiency() const;
c3ce65fd 87
c5bdf179 88private:
e7d7fa47 89 mutable Bool_t fIsValid; // Whether we were able to correctly initialize
90 Int_t fRunNumber; // The run number for which we hold calibrations
c3ce65fd 91 mutable AliMUONV2DStore* fGains; //!
92 mutable AliMUONV2DStore* fPedestals; //!
93 mutable AliMUONV2DStore* fDeadChannels; //!
e7d7fa47 94 mutable AliMUONV1DStore* fLocalTriggerBoardMasks; //!
95 mutable AliMUONV1DStore* fRegionalTriggerBoardMasks; //!
96 mutable AliMUONVCalibParam* fGlobalTriggerBoardMasks; //!
97 mutable AliMUONTriggerLut* fTriggerLut; //!
98 mutable AliMUONTriggerEfficiencyCells* fTriggerEfficiency; //!
c5bdf179 99
e7d7fa47 100 ClassDef(AliMUONCalibrationData,3) // Storage for all MUON calibration data.
c5bdf179 101};
102
103#endif