1 /***************************************************************************
2 * Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4 * Author: The ALICE Off-line Project. *
5 * Contributors are mentioned in the code where appropriate. *
7 * Permission to use, copy, modify and distribute this software and its *
8 * documentation strictly for non-commercial purposes is hereby granted *
9 * without fee, provided that the above copyright notice appears in all *
10 * copies and that both the copyright notice and this permission notice *
11 * appear in the supporting documentation. The authors make no claims *
12 * about the suitability of this software for any purpose. It is *
13 * provided "as is" without express or implied warranty. *
14 **************************************************************************/
19 #include "AliCDBEntry.h"
20 #include "AliPMDHotData.h"
23 ClassImp(AliPMDHotData)
25 AliPMDHotData::AliPMDHotData()
27 // Default constructor
30 // ----------------------------------------------------------------- //
31 AliPMDHotData::AliPMDHotData(const char* name)
34 TString namst = "hot_";
36 SetName(namst.Data());
37 SetTitle(namst.Data());
41 // ----------------------------------------------------------------- //
42 AliPMDHotData::AliPMDHotData(const AliPMDHotData& hotda) :
46 SetName(hotda.GetName());
47 SetTitle(hotda.GetName());
49 for(Int_t det = 0; det < kDet; det++)
51 for(Int_t smn = 0; smn < kModule; smn++)
53 for(Int_t row = 0; row < kRow; row++)
55 for(Int_t col = 0; col < kCol; col++)
57 fHotChannel[det][smn][row][col] = hotda.GetHotChannel(det,smn,row,col);
63 // ----------------------------------------------------------------- //
64 AliPMDHotData &AliPMDHotData::operator =(const AliPMDHotData& hotda)
67 SetName(hotda.GetName());
68 SetTitle(hotda.GetName());
70 for(Int_t det = 0; det < kDet; det++)
72 for(Int_t smn = 0; smn < kModule; smn++)
74 for(Int_t row = 0; row < kRow; row++)
76 for(Int_t col = 0; col < kCol; col++)
78 fHotChannel[det][smn][row][col] = hotda.GetHotChannel(det,smn,row,col);
85 // ----------------------------------------------------------------- //
86 AliPMDHotData::~AliPMDHotData()
90 // ----------------------------------------------------------------- //
91 void AliPMDHotData::Reset()
94 for(Int_t det = 0; det < kDet; det++)
96 for(Int_t smn = 0; smn < kModule; smn++)
98 for(Int_t row = 0; row < kRow; row++)
100 for(Int_t col = 0; col < kCol; col++)
102 fHotChannel[det][smn][row][col] = 0.;
108 // ----------------------------------------------------------------- //
109 // ----------------------------------------------------------------- //
110 Float_t AliPMDHotData:: GetHotChannel(Int_t det, Int_t smn, Int_t row, Int_t col) const
112 return fHotChannel[det][smn][row][col];
114 void AliPMDHotData::SetHotChannel(Int_t det, Int_t smn, Int_t row, Int_t col, Float_t flag)
116 fHotChannel[det][smn][row][col] = flag;
118 //------------------------------------------------------------------------------ //
119 void AliPMDHotData::Print(Option_t *) const
121 printf("\n ######Flag for each cells ####\n");
122 for(Int_t det = 0; det < kDet; det++)
124 for(Int_t smn = 0; smn < kModule; smn++)
126 for(Int_t row = 0; row < kRow; row++)
128 for(Int_t col = 0; col < kCol; col++)
130 printf("Flag[%d,%d,%d,%d]= %4.1f \n",det,smn,row,col,
131 fHotChannel[det][smn][row][col]);