]> git.uio.no Git - u/mrichter/AliRoot.git/blob - MUON/AliMUONCDB.h
Remove the dollar-id-dollar in the responsible name which interfere with CDB_MD metad...
[u/mrichter/AliRoot.git] / MUON / AliMUONCDB.h
1 #ifndef ALIMUONCDB_H
2 #define ALIMUONCDB_H
3 /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4  * See cxx source for full Copyright notice                               */
5
6 /* $Id$ */
7
8 /// \ingroup rec
9 /// \namespace AliMUONCDB
10 /// \brief Helper functions to experience the OCDB
11 /// 
12 //  Author Laurent Aphecetche
13
14 #include <TString.h>
15 #include "AliCDBRunRange.h"
16 #include <vector>
17
18 class AliMUONVStore;
19 class TMap;
20 class TClonesArray;
21 class AliMUONVCalibParam;
22 class AliMUONTriggerLut;
23 class AliMUONTriggerEfficiencyCells;
24 class AliMUONRegionalTriggerConfig;
25 class AliMUONGlobalCrateConfig;
26 class AliMUONRejectList;
27 class AliMUONRecoParam;
28 class TH1;
29
30 namespace AliMUONCDB
31 {
32   Bool_t CheckOCDB(Bool_t pathOnly = kFALSE);
33   Bool_t CheckMapping(Bool_t segmentationOnly = kFALSE);
34   
35   void CheckHV(Int_t runNumber, Int_t verbose=0);
36
37   Bool_t LoadField();
38   Bool_t LoadMapping(Bool_t segmentationOnly = kFALSE);
39   AliMUONRecoParam* LoadRecoParam();
40   TClonesArray* LoadAlignmentData();
41   
42   Int_t MakeNeighbourStore(AliMUONVStore& neighbourStore);
43
44   Int_t MakeHVStore(TMap& aliasMap, Bool_t defaultValues);
45   Int_t MakeTriggerDCSStore(TMap& aliasMap, Bool_t defaultValues);
46   Int_t MakePedestalStore(AliMUONVStore& pedestalStore, Bool_t defaultValues);
47   Int_t MakeCapacitanceStore(AliMUONVStore& capaStore, Bool_t defaultValues);
48   Int_t MakeCapacitanceStore(AliMUONVStore& capaStore, const char* file);
49   Int_t MakeGainStore(AliMUONVStore& gainStore, Bool_t defaultValues);
50   Int_t MakeOccupancyMapStore(AliMUONVStore& occupancyMap, Bool_t defaultValues);
51   AliMUONRejectList* MakeRejectListStore(Bool_t defaultValues);
52   
53   Int_t MakeLocalTriggerMaskStore(AliMUONVStore& ltm);  
54   Int_t MakeRegionalTriggerConfigStore(AliMUONRegionalTriggerConfig& rtm);
55   Int_t MakeGlobalTriggerConfigStore(AliMUONGlobalCrateConfig& gtm);
56   
57   AliMUONTriggerLut* MakeTriggerLUT(const char* file="$(ALICE_ROOT)/MUON/data/lutAptLpt1Hpt1p7.root");
58   AliMUONTriggerEfficiencyCells* MakeTriggerEfficiency(const char* file="$ALICE_ROOT/MUON/data/efficiencyCells.dat");
59
60   AliMUONVStore* Diff(AliMUONVStore& store1, AliMUONVStore& store2, const char* opt="abs");
61   
62   TH1** Plot(const AliMUONVStore& store, const char* name, Int_t nbins=512);
63
64   void ReadIntegers(const char* filename, std::vector<int>& integers);
65
66   void ShowConfig(Bool_t withStatusMap=kFALSE);
67   
68   void ShowCapacitances();
69   
70   void ShowFaultyBusPatches(const char* runlist, 
71                             double occLimit=0.1,
72                             const char* outputBaseName="faulty.buspatches",
73                             const char* ocdbPath="raw://");
74   
75   void WriteToCDB(const char* calibpath, TObject* object,
76                   Int_t startRun, Int_t endRun, Bool_t defaultValues);
77   void WriteToCDB(const char* calibpath, TObject* object,
78                   Int_t startRun, Int_t endRun, const char* filename);
79   void WriteToCDB(TObject* object, const char* calibpath, Int_t startRun=0, Int_t endRun=AliCDBRunRange::Infinity(),
80                   const char* comment="", const char* responsible="AliMUONCDB tester class");
81
82   void WriteTrigger(Bool_t defaultValues=kTRUE, Int_t startRun=0,Int_t endRun=AliCDBRunRange::Infinity());
83   void WriteTracker(Bool_t defaultValues=kTRUE, Int_t startRun=0,Int_t endRun=AliCDBRunRange::Infinity());
84   
85   void WriteNeighbours(Int_t startRun=0, Int_t endRun=AliCDBRunRange::Infinity());
86   void WriteHV(Bool_t defaultValues, Int_t startRun, Int_t endRun=AliCDBRunRange::Infinity());
87   void WritePedestals(Bool_t defaultValues, Int_t startRun, Int_t endRun=AliCDBRunRange::Infinity());
88   void WriteGains(Bool_t defaultValues, Int_t startRun, Int_t endRun=AliCDBRunRange::Infinity());
89   void WriteCapacitances(Bool_t defaultValues, Int_t startRun=0, Int_t endRun=AliCDBRunRange::Infinity());
90   void WriteCapacitances(const char* file, Int_t startRun=0, Int_t endRun=AliCDBRunRange::Infinity());
91   void WriteOccupancyMap(Bool_t defaultValues, Int_t startRun, Int_t endRun=AliCDBRunRange::Infinity());
92   void WriteRejectList(Bool_t defaultValues, Int_t startRun, Int_t endRun=AliCDBRunRange::Infinity());
93   void WriteConfig(Int_t startRun, Int_t endRun=AliCDBRunRange::Infinity());
94
95   void WriteLocalTriggerMasks(Int_t startRun=0, Int_t endRun=AliCDBRunRange::Infinity());
96   void WriteRegionalTriggerConfig(Int_t startRun=0, Int_t endRun=AliCDBRunRange::Infinity());
97   void WriteGlobalTriggerConfig(Int_t startRun=0, Int_t endRun=AliCDBRunRange::Infinity());
98   
99   void WriteTriggerDCS(Bool_t defaultValues, Int_t startRun, Int_t endRun=AliCDBRunRange::Infinity());
100   void WriteTriggerLut(Int_t startRun=0, Int_t endRun=AliCDBRunRange::Infinity());
101   void WriteTriggerEfficiency(Int_t startRun=0, Int_t endRun=AliCDBRunRange::Infinity());
102 }
103
104 #endif