(NvE) Also memberfunction MakeCopy introduced in class AliCalorimeter.
[u/mrichter/AliRoot.git] / MONITOR / AliMonitorProcess.h
CommitLineData
04fa961a 1#ifndef ALIMONITORPROCESS_H
2#define ALIMONITORPROCESS_H
3/* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4 * See cxx source for full Copyright notice */
5
6/* $Id$ */
7
8#include <TObject.h>
9#include <TString.h>
10#include <TFolder.h>
11#include <TFile.h>
12#include <TTree.h>
13#include <TObjArray.h>
14#include <TServerSocket.h>
15#include <TTimer.h>
16#include <TGrid.h>
17#include "AliRunLoader.h"
18#include "AliRawReader.h"
19#include "AliTPCParam.h"
20#include "AliITSgeom.h"
97d6eb66 21#ifdef ALI_HLT
22#include "AliLevel3.h"
23#endif
04fa961a 24
25
26class AliMonitorProcess : public TObject {
27public:
28 AliMonitorProcess(const char* alienDir,
29 const char* fileNameGalice = "galice.root");
30 virtual ~AliMonitorProcess();
31
32 static const char* GetRevision();
33
34 void Run();
35 void Stop();
36 void Reset();
37
38 void ProcessFile(const char* fileName);
39
40 UInt_t GetRunNumber() {return fRunNumber;};
41 UInt_t GetEventPeriodNumber();
42 UInt_t GetEventOrbitNumber();
43 UInt_t GetEventBunchNumber();
44
45 enum EStatus {kStopped, kWaiting, kReading, kRecTPC, kRecITS, kRecV0s,
97d6eb66 46 kRecHLT, kFilling, kUpdating, kWriting, kResetting,
04fa961a 47 kConnecting, kBroadcasting};
48 EStatus GetStatus() {return fStatus;};
49 Bool_t WillStop() {return fStopping;};
50 Bool_t IsStopped() {return (fStatus == kStopped);};
51
52 Int_t GetNumberOfEvents() {return fNEvents;};
53 Int_t GetNumberOfClients() {return fSockets.GetEntriesFast();};
54 TObjArray* GetListOfClients() {return &fSockets;};
55 Int_t GetNEventsMin() {return fNEventsMin;};
56 void SetNEventsMin(Int_t nEventsMin) {fNEventsMin = nEventsMin;};
57 void SetWriteHistoList(Bool_t writeHistoList = kTRUE)
58 {fWriteHistoList = writeHistoList;};
59
60 static const Int_t kgPort;
61
62private:
63 Bool_t CheckForNewFile();
64 Bool_t ProcessFile();
65 Int_t GetNumberOfEvents(const char* fileName);
66 Bool_t ReconstructTPC(AliRawReader* rawReader);
67 Bool_t ReconstructITS(AliRawReader* rawReader);
68 Bool_t ReconstructV0s();
97d6eb66 69#ifdef ALI_HLT
70 void CreateHLT(const char* fileName);
71#endif
72 Bool_t ReconstructHLT(Int_t iEvent);
04fa961a 73
74 Bool_t WriteHistos();
75 void StartNewRun();
76
77 void CheckForConnections();
78 void BroadcastHistos();
79
80 TGrid* fGrid;
81 AliRunLoader* fRunLoader;
82 AliTPCParam* fTPCParam;
83 AliITSgeom* fITSgeom;
84 TString fLogicalFileName;
85 TString fFileName;
97d6eb66 86#ifdef ALI_HLT
87 AliLevel3* fHLT;
88#endif
04fa961a 89
90 UInt_t fRunNumber;
91 UInt_t fSubRunNumber;
92 UInt_t fEventNumber[2];
93 Int_t fNEvents;
94 Int_t fNEventsMin;
95 Bool_t fWriteHistoList;
96
97 TFolder* fTopFolder;
98 TObjArray fMonitors;
99 TFile* fFile;
100 TTree* fTree;
101
102 TServerSocket* fServerSocket;
103 TObjArray fSockets;
104 TSocket* fDisplaySocket;
105
106 EStatus fStatus;
107 Bool_t fStopping;
108
109 ClassDef(AliMonitorProcess, 0) // class for performing the monitoring
110};
111
112
113#endif
114
115
116
117
118
119
120
121
122