fix in destructor: histos owned by the output were deleted (Ruben)
[u/mrichter/AliRoot.git] / VZERO / AliVZEROReconstructor.h
CommitLineData
b0d2c2d3 1#ifndef ALIVZERORECONSTRUCTOR_H
2#define ALIVZERORECONSTRUCTOR_H
35b120ff 3/* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved.*/
4/* See cxx source for full Copyright notice */
5/* $Id$ */
b0d2c2d3 6
35b120ff 7///////////////////////////////////////////////////////////////////////////
8/// //
9/// class for VZERO reconstruction //
10/// //
11///////////////////////////////////////////////////////////////////////////
b0d2c2d3 12
13#include "AliReconstructor.h"
ce7090f5 14#include "AliCDBManager.h"
15#include "AliCDBStorage.h"
ce7090f5 16#include "AliCDBEntry.h"
b0d2c2d3 17
35b120ff 18#include "AliLog.h"
19#include "AliESDVZERO.h"
75b6bc77 20#include "AliVZERORecoParam.h"
35b120ff 21
b44c933e 22class TF1;
e58b4e66 23class AliVZEROCalibData;
1999c0f1 24class AliVZEROTriggerData;
b14e6eb4 25class AliESDEvent;
b090e6a3 26class AliESDVZEROfriend;
b0d2c2d3 27
28class AliVZEROReconstructor: public AliReconstructor {
29public:
ce7090f5 30 AliVZEROReconstructor();
31 virtual ~AliVZEROReconstructor();
d76c31f4 32 virtual void Init();
35b120ff 33
34 virtual void Reconstruct(AliRawReader* /*rawReader*/,
2e0ee64a 35 TTree* /*clustersTree*/) const {
84dee579 36 AliError("Method not implemented"); return;};
35b120ff 37 virtual void Reconstruct(TTree*, TTree*) const {return;};
38
2e0ee64a 39 virtual void FillESD(TTree* digitsTree, TTree* /*clustersTree*/,
b14e6eb4 40 AliESDEvent* esd) const;
2e0ee64a 41
35b120ff 42 virtual void FillESD(AliRawReader* /*rawReader*/, TTree* /*clustersTree*/,
b14e6eb4 43 AliESDEvent* /*esd*/) const {
84dee579 44 AliError("Method not implemented"); return;};
35b120ff 45
2e0ee64a 46 virtual Bool_t HasDigitConversion() const { return kTRUE; }
47 virtual void ConvertDigits(AliRawReader* rawReader,
48 TTree* digitsTree) const;
75b6bc77 49
50 static const AliVZERORecoParam* GetRecoParam() { return dynamic_cast<const AliVZERORecoParam*>(AliReconstructor::GetRecoParam(12)); }
84dee579 51
ce7090f5 52 AliCDBStorage *SetStorage(const char* uri);
fe0adf2a 53 void GetCollisionMode();
54
ce7090f5 55 AliVZEROCalibData *GetCalibData() const;
b44c933e 56 Float_t CorrectLeadingTime(Int_t i, Float_t time, Float_t adc) const;
ce7090f5 57
7495d2be 58 enum {kInvalidADC = -1024,
b44c933e 59 kInvalidTime = -1024};
7495d2be 60
829852e8 61 AliESDVZERO* GetESDVZERO() { return fESDVZERO; }
62
35b120ff 63protected:
fe0adf2a 64 AliESDVZERO* fESDVZERO; // ESD output object
65 AliESDEvent* fESD; // ESD object
b090e6a3 66 AliESDVZEROfriend* fESDVZEROfriend; // ESD friend object (complete raw data)
35b120ff 67
68private:
e58b4e66 69 AliVZEROReconstructor(const AliVZEROReconstructor& reconstructor);
70 AliVZEROReconstructor& operator = (const AliVZEROReconstructor& reconstructor);
ef314913 71
35b120ff 72 AliVZEROCalibData* fCalibData; //! calibration data
1999c0f1 73 AliVZEROTriggerData* fTriggerData; //! calibration data
b44c933e 74 Float_t fTimeOffset[64]; //! HPTDC time offsets channel by channel
75 TF1* fTimeSlewing; //! Function for time slewing correction
53ad561b 76 TObjArray* fSaturationCorr; //! Array with functions for correcting the signal saturation
fe0adf2a 77
78 Int_t fCollisionMode; // =0->p-p, =1->A-A
79 Float_t fBeamEnergy; // beam energy
dbf24214 80
81 mutable TClonesArray *fDigitsArray; // clones-array for ConvertDigits() and FillESD()
82
1999c0f1 83 ClassDef(AliVZEROReconstructor, 4) // class for the VZERO reconstruction
b0d2c2d3 84};
85
86#endif