1 /////////////////////////////////////////////////////////////////////
2 // Author: Henrik Tydesjo //
4 // This class is used to store Fast-OR efficiency values in OCDB. //
5 // One value per pixel chip column in this daughter class. //
6 // The values are the probability that a pixel hit will generate a //
9 /////////////////////////////////////////////////////////////////////
11 #include "AliITSFOEfficiencySPDColumn.h"
13 AliITSFOEfficiencySPDColumn::AliITSFOEfficiencySPDColumn() :
14 AliITSFOEfficiencySPD()
16 // default constructor, sets all efficiency values to 100%
19 //______________________________________________________________________
20 AliITSFOEfficiencySPDColumn::AliITSFOEfficiencySPDColumn(const AliITSFOEfficiencySPDColumn& foEff) :
21 AliITSFOEfficiencySPD()
23 // copy constructor, copy the array values from input object
24 for (UInt_t eq=0; eq<20; eq++) {
25 for (UInt_t hs=0; hs<6; hs++) {
26 for (UInt_t chip=0; chip<10; chip++) {
27 for (UInt_t col=0; col<32; col++) {
28 fColumnEfficiency[eq][hs][chip][col] = foEff.fColumnEfficiency[eq][hs][chip][col];
34 //______________________________________________________________________
35 AliITSFOEfficiencySPDColumn::~AliITSFOEfficiencySPDColumn() {}
36 //______________________________________________________________________
37 AliITSFOEfficiencySPDColumn& AliITSFOEfficiencySPDColumn::operator=(const AliITSFOEfficiencySPDColumn& foEff) {
38 // assignment operator
40 for (UInt_t eq=0; eq<20; eq++) {
41 for (UInt_t hs=0; hs<6; hs++) {
42 for (UInt_t chip=0; chip<10; chip++) {
43 for (UInt_t col=0; col<32; col++) {
44 fColumnEfficiency[eq][hs][chip][col] = foEff.fColumnEfficiency[eq][hs][chip][col];
52 //______________________________________________________________________
53 void AliITSFOEfficiencySPDColumn::ResetValues() {
54 // set all efficiency values to 100%
55 for (UInt_t eq=0; eq<20; eq++) {
56 for (UInt_t hs=0; hs<6; hs++) {
57 for (UInt_t chip=0; chip<10; chip++) {
58 for (UInt_t col=0; col<32; col++) {
59 fColumnEfficiency[eq][hs][chip][col] = 1;
65 //______________________________________________________________________
66 void AliITSFOEfficiencySPDColumn::SetColumnEfficiency(UInt_t eq, UInt_t hs, UInt_t chip, UInt_t col, Float_t value) {
67 // set a column efficiency value
69 Error("AliITSFOEfficiencySPDColumn::SetColumnEfficiency", "eq (%d) out of bounds.",eq);
73 Error("AliITSFOEfficiencySPDColumn::SetColumnEfficiency", "hs (%d) out of bounds.",hs);
77 Error("AliITSFOEfficiencySPDColumn::SetColumnEfficiency", "chip (%d) out of bounds.",chip);
81 Error("AliITSFOEfficiencySPDColumn::SetColumnEfficiency", "col (%d) out of bounds.",col);
85 fColumnEfficiency[eq][hs][chip][col] = value;
87 //______________________________________________________________________
88 Float_t AliITSFOEfficiencySPDColumn::GetColumnEfficiency(UInt_t eq, UInt_t hs, UInt_t chip, UInt_t col) const {
89 // get a column efficiency value
91 Error("AliITSFOEfficiencySPDColumn::GetEfficiency", "eq (%d) out of bounds.",eq);
95 Error("AliITSFOEfficiencySPDColumn::GetEfficiency", "hs (%d) out of bounds.",hs);
99 Error("AliITSFOEfficiencySPDColumn::GetEfficiency", "chip (%d) out of bounds.",chip);
103 Error("AliITSFOEfficiencySPDColumn::GetEfficiency", "col (%d) out of bounds.",col);
107 return fColumnEfficiency[eq][hs][chip][col];