]> git.uio.no Git - u/mrichter/AliRoot.git/blame_incremental - MUON/AliMUONTrackerPreprocessor.cxx
adding switches for 2011 data and so that PID doesnt crash for local testing
[u/mrichter/AliRoot.git] / MUON / AliMUONTrackerPreprocessor.cxx
... / ...
CommitLineData
1/**************************************************************************
2* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
3* *
4* Author: The ALICE Off-line Project. *
5* Contributors are mentioned in the code where appropriate. *
6* *
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**************************************************************************/
15
16// $Id$
17
18#include "AliMUONTrackerPreprocessor.h"
19
20#include "AliMUONPedestalSubprocessor.h"
21#include "AliMUONHVSubprocessor.h"
22#include "AliMUONGMSSubprocessor.h"
23#include "AliMUONGainSubprocessor.h"
24#include "AliMUONOccupancySubprocessor.h"
25
26#include "AliLog.h"
27#include "AliShuttleInterface.h"
28#include "Riostream.h"
29#include "TObjArray.h"
30
31//-----------------------------------------------------------------------------
32/// \class AliMUONTrackerPreprocessor
33///
34/// Shuttle preprocessor for MUON tracker
35///
36/// It's simply a manager class that deals with a list of sub-tasks
37/// (of type AliMUONVSubprocessor).
38///
39/// \author Laurent Aphecetche
40//-----------------------------------------------------------------------------
41
42/// \cond CLASSIMP
43ClassImp(AliMUONTrackerPreprocessor)
44/// \endcond
45
46//_____________________________________________________________________________
47AliMUONTrackerPreprocessor::AliMUONTrackerPreprocessor(AliShuttleInterface* shuttle)
48: AliMUONPreprocessor("MCH",shuttle),
49fPedestalSubprocessor(new AliMUONPedestalSubprocessor(this)),
50fGMSSubprocessor(new AliMUONGMSSubprocessor(this)),
51fHVSubprocessor(new AliMUONHVSubprocessor(this,kTRUE)),
52fGainSubprocessor(new AliMUONGainSubprocessor(this)),
53fOccupancySubprocessor(new AliMUONOccupancySubprocessor(this))
54{
55 /// ctor.
56
57 AddRunType("PEDESTAL");
58 AddRunType("CALIBRATION");
59 AddRunType("GMS");
60 AddRunType("PHYSICS");
61}
62
63//_____________________________________________________________________________
64AliMUONTrackerPreprocessor::~AliMUONTrackerPreprocessor()
65{
66 /// dtor
67
68 delete fPedestalSubprocessor;
69 delete fGMSSubprocessor;
70 delete fHVSubprocessor;
71 delete fGainSubprocessor;
72 delete fOccupancySubprocessor;
73}
74
75//_____________________________________________________________________________
76void
77AliMUONTrackerPreprocessor::Initialize(Int_t run, UInt_t startTime, UInt_t endTime)
78{
79 /// Re-register the subprocessor(s) depending on the actual runType
80
81 ClearSubprocessors();
82
83 TString runType = GetRunType();
84
85 fIsValid = kTRUE;
86 fIsApplicable = kTRUE;
87
88 if ( runType == "PEDESTAL" )
89 {
90 Add(fPedestalSubprocessor); // to be called only for pedestal runs
91 Log("INFO-Will run Pedestal subprocessor");
92 }
93 else if ( runType == "CALIBRATION" )
94 {
95 Add(fGainSubprocessor); // to be called only for gain runs
96 Log("INFO-Will run Gain subprocessor");
97 }
98 else if ( runType == "GMS" )
99 {
100 Add(fGMSSubprocessor);
101 Log("INFO-Will run GMS subprocessor");
102 }
103 else if ( runType == "PHYSICS" )
104 {
105 Bool_t useDCS(kTRUE);
106 Add(fHVSubprocessor,useDCS); // to be called only for physics runs
107 Add(fOccupancySubprocessor);
108 Log("INFO-Will run HV subprocessor");
109 if ( fHVSubprocessor->IncludeHVCurrent() )
110 {
111 Log("INFO-HV subprocessor will store HV currents in addition to the voltages");
112 }
113 Log("INFO-Will run Occupancy subprocessor");
114 }
115 else
116 {
117 fIsApplicable = kFALSE;
118 }
119
120 AliMUONPreprocessor::Initialize(run,startTime,endTime);
121
122}