New SPD pre-processor (H. Tydesjo)
[u/mrichter/AliRoot.git] / ITS / AliITSOnlineSPDscanSingle.cxx
CommitLineData
b15de2d2 1////////////////////////////////////////////////////////////
2// Author: Henrik Tydesjo //
3// Interface class to the containers of an online scan //
4// with only one step. //
5////////////////////////////////////////////////////////////
6
7#include <TFile.h>
8#include "AliITSOnlineSPDscanSingle.h"
9#include "AliITSOnlineSPDscanInfo.h"
10
11ClassImp(AliITSOnlineSPDscanSingle)
12
13AliITSOnlineSPDscanSingle::AliITSOnlineSPDscanSingle(Char_t *fileName) {
14 // constructor
15 sprintf(fFileName,"%s",fileName);
16 // look for a previously saved info object
17 // (if file not found create a new one and return, else read)
18 FILE* fp0 = fopen(fFileName, "r");
19 if (fp0 == NULL) {
20 fScanInfo = new AliITSOnlineSPDscanInfo();
21 fFile = new TFile(fFileName, "RECREATE");
22 fWrite=kTRUE;
23 }
24 else {
25 fclose(fp0);
26 fFile = new TFile(fFileName, "READ");
27 fWrite=kFALSE;
28 fFile->GetObject("SPDscanInfo", fScanInfo);
29 }
30 Init();
31 if (GetNSteps()==0) {
32 AddScanStep(); // this is supposedly the only step for this object
33 }
34}
35AliITSOnlineSPDscanSingle::~AliITSOnlineSPDscanSingle() {}
36
37// call the corresponding methods in SPDscan with nsi=0 ******************
38void AliITSOnlineSPDscanSingle::SetTriggers(UInt_t val)
39 {AliITSOnlineSPDscan::SetTriggers(0,val);}
40void AliITSOnlineSPDscanSingle::SetHits(UInt_t hs, UInt_t chipi, UInt_t coli, UInt_t rowi, UInt_t val)
41 {AliITSOnlineSPDscan::SetHits(0,hs,chipi,coli,rowi,val);}
42void AliITSOnlineSPDscanSingle::IncrementTriggers()
43 {AliITSOnlineSPDscan::IncrementTriggers(0);}
44void AliITSOnlineSPDscanSingle::IncrementHits(UInt_t hs, UInt_t chipi, UInt_t coli, UInt_t rowi)
45 {AliITSOnlineSPDscan::IncrementHits(0,hs,chipi,coli,rowi);}
46void AliITSOnlineSPDscanSingle::SetHitEvents(UInt_t hs, UInt_t chipi, UInt_t val)
47 {AliITSOnlineSPDscan::SetHitEvents(0,hs,chipi,val);}
48void AliITSOnlineSPDscanSingle::SetHitEventsTot(UInt_t hs, UInt_t val)
49 {AliITSOnlineSPDscan::SetHitEventsTot(0,hs,val);}
50void AliITSOnlineSPDscanSingle::IncrementHitEvents(UInt_t hs, UInt_t chipi)
51 {AliITSOnlineSPDscan::IncrementHitEvents(0,hs,chipi);}
52void AliITSOnlineSPDscanSingle::IncrementHitEventsTot(UInt_t hs)
53 {AliITSOnlineSPDscan::IncrementHitEventsTot(0,hs);}
54UInt_t AliITSOnlineSPDscanSingle::GetTriggers()
55 {return AliITSOnlineSPDscan::GetTriggers(0);}
56UInt_t AliITSOnlineSPDscanSingle::GetHits(UInt_t hs, UInt_t chipi, UInt_t coli, UInt_t rowi)
57 {return AliITSOnlineSPDscan::GetHits(0,hs,chipi,coli,rowi);}
58Float_t AliITSOnlineSPDscanSingle::GetHitsEfficiency(UInt_t hs, UInt_t chipi, UInt_t coli, UInt_t rowi)
59 {return AliITSOnlineSPDscan::GetHitsEfficiency(0,hs,chipi,coli,rowi);}
60Float_t AliITSOnlineSPDscanSingle::GetHitsEfficiencyError(UInt_t hs, UInt_t chipi, UInt_t coli, UInt_t rowi)
61 {return AliITSOnlineSPDscan::GetHitsEfficiencyError(0,hs,chipi,coli,rowi);}
62UInt_t AliITSOnlineSPDscanSingle::GetHitEvents(UInt_t hs, UInt_t chipi)
63 {return AliITSOnlineSPDscan::GetHitEvents(0,hs,chipi);}
64UInt_t AliITSOnlineSPDscanSingle::GetHitEventsTot(UInt_t hs)
65 {return AliITSOnlineSPDscan::GetHitEventsTot(0,hs);}
66Float_t AliITSOnlineSPDscanSingle::GetHitEventsEfficiency(UInt_t hs, UInt_t chipi)
67 {return AliITSOnlineSPDscan::GetHitEventsEfficiency(0,hs,chipi);}
68Float_t AliITSOnlineSPDscanSingle::GetHitEventsTotEfficiency(UInt_t hs)
69 {return AliITSOnlineSPDscan::GetHitEventsTotEfficiency(0,hs);}
70Float_t AliITSOnlineSPDscanSingle::GetHitEventsEfficiencyError(UInt_t hs, UInt_t chipi)
71 {return AliITSOnlineSPDscan::GetHitEventsEfficiencyError(0,hs,chipi);}
72Float_t AliITSOnlineSPDscanSingle::GetHitEventsTotEfficiencyError(UInt_t hs)
73 {return AliITSOnlineSPDscan::GetHitEventsTotEfficiencyError(0,hs);}
74Float_t AliITSOnlineSPDscanSingle::GetAverageMultiplicity(UInt_t hs, UInt_t chipi)
75 {return AliITSOnlineSPDscan::GetAverageMultiplicity(0,hs,chipi);}
76Float_t AliITSOnlineSPDscanSingle::GetAverageMultiplicityTot(UInt_t hs)
77 {return AliITSOnlineSPDscan::GetAverageMultiplicityTot(0,hs);}