]>
Commit | Line | Data |
---|---|---|
9acda34c | 1 | #ifndef ALIHLTMUONROOTIFIERCOMPONENT_H |
2 | #define ALIHLTMUONROOTIFIERCOMPONENT_H | |
3 | /* This file is property of and copyright by the ALICE HLT Project * | |
4 | * ALICE Experiment at CERN, All rights reserved. * | |
5 | * See cxx source for full Copyright notice */ | |
6 | ||
1d8ae082 | 7 | // $Id$ |
9acda34c | 8 | |
cb35e21b | 9 | /// |
10 | /// @file AliHLTMUONRootifierComponent.h | |
11 | /// @author Artur Szostak <artursz@iafrica.com> | |
450e0b36 | 12 | /// @date 29 Sep 2007 |
cb35e21b | 13 | /// @brief Component for converting dHLT raw data into ROOT objects. |
14 | /// | |
9acda34c | 15 | |
154cba94 | 16 | #include "AliHLTMUONProcessor.h" |
9acda34c | 17 | |
bc5cb6d6 | 18 | class AliHLTMUONEvent; |
19 | class AliHLTMUONMansoTrack; | |
00d81682 | 20 | class AliHLTMUONTrack; |
bc5cb6d6 | 21 | extern "C" struct AliHLTMUONMansoTrackStruct; |
22 | ||
9acda34c | 23 | /** |
1d8ae082 | 24 | * \class AliHLTMUONRootifierComponent |
25 | * \brief Converts dHLT raw data blocks into ROOT objects. | |
26 | * | |
27 | * This component class is used to convert all internal raw dHLT data blocks into | |
28 | * ROOT object that can be stored in '.root' files in a platform independant manner. | |
29 | * This can also make some of the analysis easier because the dHLT internal data | |
30 | * will be available in TObjects. | |
31 | * | |
32 | * <h2>General properties:</h2> | |
33 | * | |
34 | * Component ID: \b MUONRootifier <br> | |
35 | * Library: \b libAliHLTMUON.so <br> | |
36 | * Input Data Types: kAliHLTAnyDataType = "*******:***" <br> | |
37 | * Output Data Types: AliHLTMUONConstants::RootifiedEventDataType() = "ROOTEVNT:MUON" <br> | |
38 | * | |
39 | * <h2>Mandatory arguments:</h2> | |
40 | * None. | |
41 | * | |
42 | * <h2>Optional arguments:</h2> | |
43 | * \li -warn_on_unexpected_block <br> | |
44 | * This will cause the component to generate warnings when it receives data block | |
45 | * types it does not know how to handle. Without this option the component only | |
46 | * generates debug messages when they are compiled in. <br> | |
47 | * \li -dumponerror <br> | |
48 | * This flag will cause the component to dump the data blocks it received if | |
49 | * an error occurs during the processing of an event. <br> | |
50 | * \li -dumppath <i>path</i> <br> | |
51 | * Allows one to specify the path in which to dump the received data blocks | |
52 | * if an error occurs. <br> | |
53 | * | |
54 | * <h2>Standard configuration:</h2> | |
55 | * There is no special configuration for this component. | |
56 | * | |
57 | * <h2>Default CDB entries:</h2> | |
58 | * None. | |
59 | * | |
60 | * <h2>Performance:</h2> | |
61 | * A few milliseconds per event. | |
62 | * | |
63 | * <h2>Memory consumption:</h2> | |
64 | * A few MBytes. | |
65 | * | |
66 | * <h2>Output size:</h2> | |
67 | * A few kBytes. | |
68 | * | |
ebf7a8e8 | 69 | * @ingroup alihlt_muon_components |
9acda34c | 70 | */ |
154cba94 | 71 | class AliHLTMUONRootifierComponent : public AliHLTMUONProcessor |
9acda34c | 72 | { |
73 | public: | |
74 | ||
75 | AliHLTMUONRootifierComponent(); | |
76 | virtual ~AliHLTMUONRootifierComponent(); | |
77 | ||
9acda34c | 78 | virtual const char* GetComponentID(); |
79 | ||
ffb64d3e | 80 | virtual void GetInputDataTypes(AliHLTComponentDataTypeList& list); |
9acda34c | 81 | virtual AliHLTComponentDataType GetOutputDataType(); |
bb14e9db | 82 | virtual int GetOutputDataTypes(AliHLTComponentDataTypeList& tgtList); |
9acda34c | 83 | virtual void GetOutputDataSize(unsigned long& constBase, double& inputMultiplier); |
84 | ||
85 | virtual AliHLTComponent* Spawn(); | |
86 | ||
87 | protected: | |
88 | ||
89 | virtual int DoInit(int argc, const char** argv); | |
90 | virtual int DoDeinit(); | |
6253e09b | 91 | virtual int DoEvent(const AliHLTComponentEventData& evtData, AliHLTComponentTriggerData& trigData); |
ffb64d3e | 92 | virtual bool IgnoreArgument(const char* arg) const; |
6253e09b | 93 | using AliHLTProcessor::DoEvent; |
9acda34c | 94 | |
95 | private: | |
96 | ||
97 | // Prevent copying of these objects. | |
98 | AliHLTMUONRootifierComponent(const AliHLTMUONRootifierComponent& /*object*/); | |
99 | AliHLTMUONRootifierComponent& operator = (const AliHLTMUONRootifierComponent& /*object*/); | |
450e0b36 | 100 | |
bc5cb6d6 | 101 | /** |
102 | * This method creates a AliHLTMUONMansoTrack object from the track structure | |
103 | * and adds it to the dHLT event object. | |
104 | * \param event The dHLT event object. | |
105 | * \param track The track structure to convert and add to the event. | |
106 | */ | |
107 | AliHLTMUONMansoTrack* AddTrack(AliHLTMUONEvent& event, const AliHLTMUONMansoTrackStruct& track); | |
108 | ||
00d81682 | 109 | /** |
110 | * This method creates a AliHLTMUONTrack object from the given track structure | |
111 | * and adds it to the dHLT event object. | |
112 | * \param event The dHLT event object. | |
113 | * \param track The track structure to convert and add to the event. | |
114 | */ | |
115 | AliHLTMUONTrack* AddTrack(AliHLTMUONEvent& event, const AliHLTMUONTrackStruct& track); | |
116 | ||
450e0b36 | 117 | bool fWarnForUnexpecedBlock; /// Flag indicating if we should log a warning if we got a block of an unexpected type. |
9acda34c | 118 | |
119 | ClassDef(AliHLTMUONRootifierComponent, 0); // Converter component of dHLT raw data. | |
120 | }; | |
121 | ||
122 | #endif // ALIHLTMUONROOTIFIERCOMPONENT_H |