]>
Commit | Line | Data |
---|---|---|
2ff24e4c | 1 | //-*- Mode: C++ -*- |
2 | // $Id$ | |
3 | #ifndef ALIHLTRUNSUMMARY_H | |
4 | #define ALIHLTRUNSUMMARY_H | |
5 | ||
6 | /* This file is property of and copyright by the ALICE HLT Project * | |
7 | * ALICE Experiment at CERN, All rights reserved. * | |
8 | * See cxx source for full Copyright notice */ | |
9 | ||
10 | /** @file AliHLTRunSummary.h | |
11 | @author Jochen Thaeder | |
12 | @date | |
13 | @brief Summary class for a run, merges all detectors | |
14 | */ | |
15 | ||
16 | // see below for class documentation | |
17 | // or | |
18 | // refer to README to build package | |
19 | // or | |
20 | // visit http://web.ift.uib.no/~kjeks/doc/alice-hlt | |
21 | ||
22 | #include "TObject.h" | |
23 | #include "TObjArray.h" | |
24 | ||
25 | #include "AliHLTDataTypes.h" | |
26 | ||
27 | /** | |
28 | * @class AliHLTRunSummary | |
29 | * @brief Summary class for a run, merges all detectors | |
30 | * | |
31 | * The run statistic classes hold information / histograms about certain | |
32 | * characteristica of the processed events. They are devided into 3 parts. | |
33 | * A base class @see AliHLTRunStatistics for general Information, detector | |
34 | * specific classes like @see AliHLTTPCRunStatistics for the TPC and a summary | |
35 | * class @see AliHLTRunSummary which can hold several detector classes. | |
36 | * | |
37 | * This is the summary class. | |
38 | * | |
39 | * See base class @see AliHLTRunStatistics for further information. | |
40 | * | |
41 | * @ingroup alihlt_run_statistics alihlt_trigger | |
42 | */ | |
43 | ||
44 | class AliHLTRunSummary : public TObject { | |
45 | ||
46 | public: | |
47 | ||
48 | /** constructor */ | |
49 | AliHLTRunSummary(); | |
50 | /** destructor */ | |
51 | virtual ~AliHLTRunSummary(); | |
52 | ||
53 | // -- event parameters ------------------------ | |
54 | ||
55 | /** Set Number of events | |
56 | * @param i number of events | |
57 | */ | |
58 | void SetNEvents( ULong_t i ) { fNEvents = i; } | |
59 | ||
60 | /** Add events */ | |
61 | void AddNEvents() { fNEvents++; } | |
62 | ||
63 | /** Get number of events | |
64 | * @return number of events | |
65 | */ | |
52f67e50 | 66 | ULong_t GetNEvents() const { return fNEvents; } |
2ff24e4c | 67 | |
68 | /** Set number of rejected events | |
69 | * @param i number of events rejected | |
70 | */ | |
71 | void SetNEventsRejected( ULong_t i ) { fNEventsRejected = i; } | |
72 | ||
73 | /** Add rejected events */ | |
74 | void AddNEventsRejected() { fNEventsRejected++; } | |
75 | ||
76 | /** Get number of reejcted events | |
77 | * @return number of events rejected | |
78 | */ | |
52f67e50 | 79 | ULong_t GetNEventsRejected() const { return fNEventsRejected; } |
2ff24e4c | 80 | |
81 | // -- run parameters ------------------------ | |
82 | ||
83 | /** Set Run Number | |
84 | * @param i run number | |
85 | */ | |
86 | void SetRunNumber( AliHLTUInt32_t i ) { fRunNumber = i; } | |
87 | ||
88 | /** Get Run Number | |
89 | * @return run number | |
90 | */ | |
52f67e50 | 91 | AliHLTUInt32_t GetRunNumber() const { return fRunNumber;} |
2ff24e4c | 92 | |
93 | /** Set Run Type | |
94 | * @param i run type | |
95 | */ | |
96 | void SetRunType( AliHLTUInt32_t i ) { fRunType = i; } | |
97 | ||
98 | /** Get Run Type s | |
99 | * @return run type | |
100 | */ | |
52f67e50 | 101 | AliHLTUInt32_t GetRunType() const { return fRunType; } |
2ff24e4c | 102 | |
103 | // -- trigger parameters ------------------------ | |
104 | ||
105 | /** Set ocurrance of trigger classe with index ndx | |
106 | * @param ndx index of Trigger Class | |
107 | * @return kTRUE on success | |
108 | */ | |
109 | Bool_t AddTriggerClass( Int_t ndx ); | |
110 | ||
111 | /** Get ocurrance of trigger classes | |
112 | * @return ptr to array of trigger classes | |
113 | */ | |
52f67e50 | 114 | const ULong_t* GetTriggerClasses() const { return fTriggerClasses; } |
115 | ULong_t* GetTriggerClasses() { return fTriggerClasses; } | |
2ff24e4c | 116 | |
117 | // -- detector parameters ------------------------ | |
118 | ||
119 | /** Detector run statistics classes | |
120 | * @return ptr to Detector arry | |
121 | */ | |
122 | TObjArray* GetDetectorArray () { return fDetectorArray; } | |
123 | ||
124 | /** Rest the Detector array, all elements are removed */ | |
125 | void ResetDetectorArray() { if ( fDetectorArray ) fDetectorArray->Clear(); } | |
126 | ||
127 | /** Add another detector run statistics class to detector arry | |
128 | * @param obj to TObject, which should be added | |
129 | * @return kTRUE on success | |
130 | */ | |
131 | Bool_t AddDetector( TObject *obj ); | |
132 | ||
133 | private: | |
134 | ||
135 | /** copy constructor prohibited */ | |
136 | AliHLTRunSummary (const AliHLTRunSummary&); | |
137 | ||
138 | /** assignment operator prohibited */ | |
139 | AliHLTRunSummary& operator= (const AliHLTRunSummary&); | |
140 | ||
141 | /** Number of events */ | |
142 | ULong_t fNEvents; // see above | |
143 | ||
144 | /** Number of rejected events */ | |
145 | ULong_t fNEventsRejected; // see above | |
146 | ||
147 | /** Run Number */ | |
148 | AliHLTUInt32_t fRunNumber; // see above | |
149 | ||
150 | /** Run Type */ | |
151 | AliHLTUInt32_t fRunType; // see above | |
152 | ||
153 | /** Ocurrance of trigger classes */ | |
154 | ULong_t fTriggerClasses[gkNCTPTriggerClasses]; // see above | |
155 | ||
156 | /** Detector run statistics classes */ | |
157 | TObjArray* fDetectorArray; //! transient | |
158 | ||
325e5e42 | 159 | ClassDef(AliHLTRunSummary, 1); |
2ff24e4c | 160 | }; |
161 | #endif |