Changes needed by the ZDC calibration (A.Colla)
[u/mrichter/AliRoot.git] / ZDC / AliZDC.h
CommitLineData
68ca986e 1#ifndef ALIZDC_H
2#define ALIZDC_H
3da30618 3/* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4 * See cxx source for full Copyright notice */
5
6/* $Id$ */
7
fe4da5cc 8////////////////////////////////////////////////
f901045b 9// Manager and classes for set ZDC //
fe4da5cc 10////////////////////////////////////////////////
359cdddc 11
4d81e5e7 12#include <TSystem.h>
13
fe4da5cc 14#include "AliDetector.h"
8af17dba 15
16class AliZDCCalibData;
fe4da5cc 17
18class AliZDC : public AliDetector {
19
20public:
21 AliZDC();
22 AliZDC(const char *name, const char *title);
f901045b 23 virtual ~AliZDC();
68ca986e 24 virtual void AddHit(Int_t track, Int_t *vol, Float_t *hits);
fe4da5cc 25 virtual void BuildGeometry();
26 virtual void CreateGeometry() {}
27 virtual void CreateMaterials() {}
f901045b 28 Int_t DistancetoPrimitive(Int_t px, Int_t py);
fe4da5cc 29 virtual Int_t IsVersion() const =0;
cefa66cb 30 virtual Float_t ZMin() const; // Minimum overall dimension of the ZDC
31 virtual Float_t ZMax() const; // Maximum overall dimension of the ZDC
b81c9821 32 virtual void SetTreeAddress();
359cdddc 33 virtual void MakeBranch(Option_t* opt, const char *file=0);
34 virtual void Hits2SDigits();
6de91202 35 virtual AliDigitizer* CreateDigitizer(AliRunDigitizer* manager) const;
36 virtual void Digits2Raw();
359cdddc 37 virtual void StepManager() {}
1acbaaa8 38
3d0b2c4f 39 // Switching off the shower development in ZDCs
09630792 40 void NoShower(){fNoShower=1;}
41 void Shower() {fNoShower=0;}
359cdddc 42
8af17dba 43
44//Calibration methods (by Alberto Colla)
4d81e5e7 45// Albe
46
47public:
48 void SetZDCCalibFName(const char *name="$(ALICE)/AliRoot/data/AliZDCCalib.root");
49 char* GetZDCCalibFName() const;
50 TString fZDCCalibFName; // Name of the ZDC calibration data
51
8af17dba 52 void CreateCalibData();
53 void WriteCalibData(Int_t option=TObject::kOverwrite);
54 void LoadCalibData();
55 void SetCalibData(AliZDCCalibData* data) {fCalibData = data;}
56 AliZDCCalibData* GetCalibData() const {return fCalibData;}
57//Calibration methods (by Alberto Colla)
58
59
68ca986e 60protected:
359cdddc 61
62 Int_t fNoShower; // Flag to switch off the shower
8af17dba 63
64//Calibration methods (by Alberto Colla)
65 AliZDCCalibData* fCalibData; // Calibration data for ZDC
66//Calibration methods (by Alberto Colla)
1acbaaa8 67
6de91202 68 ClassDef(AliZDC,4) // Zero Degree Calorimeter base class
fe4da5cc 69};
fe4da5cc 70
8af17dba 71R__EXTERN AliZDC *gZDC;
72
4d81e5e7 73
74// Calibration methods (by Alberto Colla)
75//_____________________________________________________________________________
76inline void AliZDC::SetZDCCalibFName(const char *name)
77{fZDCCalibFName = name; gSystem->ExpandPathName(fZDCCalibFName);}
78//_____________________________________________________________________________
79inline char* AliZDC::GetZDCCalibFName() const {return (char*)fZDCCalibFName.Data();}
80
81// Calibration methods (by Alberto Colla)
82
83
fe4da5cc 84#endif