]>
Commit | Line | Data |
---|---|---|
2ff24e4c | 1 | //-*- Mode: C++ -*- |
2 | // $Id$ | |
3 | #ifndef ALIHLTTPCEVENTSTATISTICSPRODUCERCOMPONENT_H | |
4 | #define ALIHLTTPCEVENTSTATISTICSPRODUCERCOMPONENT_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 AliHLTTPCEventStatisticsProducerComponent.h | |
11 | @author Jochen Thaeder | |
12 | @date | |
13 | @brief Component for the @see AliHLTTPCEventStatisticsProducer class | |
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 "AliHLTProcessor.h" | |
23 | ||
24 | #include "AliHLTTPCEventStatistics.h" | |
25 | #include "AliHLTTPCTrackArray.h" | |
26 | ||
27 | /** | |
28 | * @class AliHLTTPCEventStatisticsProducerComponent | |
29 | * @brief Component for the @see AliHLTTPCEventStatisticsProducer class | |
30 | * | |
31 | * | |
32 | * @ingroup alihlt_run_statistics alihlt_trigger | |
33 | */ | |
34 | ||
35 | class AliHLTTPCEventStatisticsProducerComponent : public AliHLTProcessor { | |
36 | ||
37 | public: | |
38 | ||
39 | /** constructor */ | |
40 | AliHLTTPCEventStatisticsProducerComponent(); | |
41 | /** destructor */ | |
42 | virtual ~AliHLTTPCEventStatisticsProducerComponent(); | |
43 | ||
44 | // Public functions to implement AliHLTComponent's interface. | |
45 | // These functions are required for the registration process | |
46 | ||
47 | const char* GetComponentID(); | |
48 | void GetInputDataTypes( AliHLTComponentDataTypeList& list ); | |
49 | ||
50 | AliHLTComponentDataType GetOutputDataType(); | |
2ff24e4c | 51 | |
52 | virtual void GetOutputDataSize( unsigned long& constBase, double& inputMultiplier ); | |
53 | AliHLTComponent* Spawn(); | |
54 | ||
55 | protected: | |
56 | ||
57 | using AliHLTProcessor::DoEvent; | |
58 | ||
59 | // Protected functions to implement AliHLTComponent's interface. | |
60 | // These functions provide initialization as well as the actual processing | |
61 | // capabilities of the component. | |
62 | ||
63 | /** Initialize the trigger component. */ | |
64 | Int_t DoInit( int argc, const char** argv ); | |
65 | ||
66 | /** DeInitialize the trigger component. */ | |
67 | Int_t DoDeinit(); | |
68 | ||
69 | /** Process the data in the trigger component */ | |
70 | Int_t DoEvent( const AliHLTComponentEventData& evtData, AliHLTComponentTriggerData& trigData); | |
71 | ||
72 | // ------------------------------------------------------------------------------------------ | |
73 | ||
74 | /** Initialize for next event */ | |
75 | void InitializeEvent(); | |
76 | ||
77 | /** Add new cluster block | |
78 | * @param ptr Pointer to data block | |
79 | * @param size Size of data block | |
80 | * @param slice Slice | |
81 | * @param patch Patch | |
82 | */ | |
5eefc803 | 83 | void AddClusters( void* ptr, Int_t slice, Int_t patch ); |
2ff24e4c | 84 | |
85 | /** Add new tracks block | |
86 | * @param ptr Pointer to data block | |
87 | * @param size Size of data block | |
88 | * @param slice Slice, default is -1 for GlobalMerger tracks | |
89 | */ | |
5eefc803 | 90 | void AddTracks( void* ptr, Int_t slice=-1 ); |
2ff24e4c | 91 | |
92 | /** Process even -> get process statistics */ | |
93 | void ProcessEvent(); | |
94 | ||
95 | /** Fill tracks per slice ( @see fNTracksPerSlice ), if global tracks */ | |
96 | void FillTracksPerSlice(); | |
97 | ||
98 | /** Get ptr to @see AliHLTTPCEventStatistics, is a TObject */ | |
99 | AliHLTTPCEventStatistics* GetEventStatistics() { return fEvStat; } | |
100 | ||
101 | private: | |
102 | ||
103 | /** copy constructor prohibited */ | |
104 | AliHLTTPCEventStatisticsProducerComponent (const AliHLTTPCEventStatisticsProducerComponent&); | |
105 | ||
106 | /** assignment operator prohibited */ | |
107 | AliHLTTPCEventStatisticsProducerComponent& operator= (const AliHLTTPCEventStatisticsProducerComponent&); | |
108 | ||
109 | /** Threshold for long tracks */ | |
110 | Int_t fClusterThreshold; // see above | |
111 | ||
112 | /** Event Statistics class*/ | |
113 | AliHLTTPCEventStatistics* fEvStat; //! transient | |
114 | ||
115 | /** Tracks per slice */ | |
116 | Int_t fNTracksPerSlice[36]; // see above | |
117 | ||
118 | /** Track container of class @see AliHLTTPCTrackArray */ | |
119 | AliHLTTPCTrackArray *fTracks; //! transient | |
120 | ||
121 | /** If tracks in global coordinates @see fTracksPerSlice has still to be filled */ | |
122 | Bool_t fGlobalTracks; // see above | |
123 | ||
124 | /** Number of slices with tracks */ | |
125 | Int_t fNSlice; // see above | |
126 | ||
127 | ClassDef(AliHLTTPCEventStatisticsProducerComponent, 0); | |
128 | ||
129 | }; | |
130 | #endif | |
131 |