]> git.uio.no Git - u/mrichter/AliRoot.git/blob - HLT/MUON/OfflineInterface/AliHLTMUONRootifierComponent.h
326985143802af23fc26e3e9b716f44c1b74e800
[u/mrichter/AliRoot.git] / HLT / MUON / OfflineInterface / AliHLTMUONRootifierComponent.h
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
7 // $Id$
8
9 ///
10 /// @file   AliHLTMUONRootifierComponent.h
11 /// @author Artur Szostak <artursz@iafrica.com>
12 /// @date   29 Sep 2007
13 /// @brief  Component for converting dHLT raw data into ROOT objects.
14 ///
15
16 #include "AliHLTMUONProcessor.h"
17
18 /**
19  * \class AliHLTMUONRootifierComponent
20  * \brief Converts dHLT raw data blocks into ROOT objects.
21  *
22  * This component class is used to convert all internal raw dHLT data blocks into
23  * ROOT object that can be stored in '.root' files in a platform independant manner.
24  * This can also make some of the analysis easier because the dHLT internal data
25  * will be available in TObjects.
26  *
27  * <h2>General properties:</h2>
28  *
29  * Component ID: \b MUONRootifier <br>
30  * Library: \b libAliHLTMUON.so <br>
31  * Input Data Types:  kAliHLTAnyDataType = "*******:***" <br>
32  * Output Data Types: AliHLTMUONConstants::RootifiedEventDataType() = "ROOTEVNT:MUON" <br>
33  *
34  * <h2>Mandatory arguments:</h2>
35  * None.
36  *
37  * <h2>Optional arguments:</h2>
38  * \li -warn_on_unexpected_block <br>
39  *      This will cause the component to generate warnings when it receives data block
40  *      types it does not know how to handle. Without this option the component only
41  *      generates debug messages when they are compiled in. <br>
42  * \li -dumponerror <br>
43  *      This flag will cause the component to dump the data blocks it received if
44  *      an error occurs during the processing of an event. <br>
45  * \li -dumppath <i>path</i> <br>
46  *      Allows one to specify the path in which to dump the received data blocks
47  *      if an error occurs. <br>
48  *
49  * <h2>Standard configuration:</h2>
50  * There is no special configuration for this component.
51  *
52  * <h2>Default CDB entries:</h2>
53  * None.
54  *
55  * <h2>Performance:</h2>
56  * A few milliseconds per event.
57  *
58  * <h2>Memory consumption:</h2>
59  * A few MBytes.
60  *
61  * <h2>Output size:</h2>
62  * A few kBytes.
63  *
64  * @ingroup alihlt_dimuon_component
65  */
66 class AliHLTMUONRootifierComponent : public AliHLTMUONProcessor
67 {
68 public:
69
70         AliHLTMUONRootifierComponent();
71         virtual ~AliHLTMUONRootifierComponent();
72         
73         virtual const char* GetComponentID();
74
75         virtual void GetInputDataTypes(AliHLTComponentDataTypeList& list);
76         virtual AliHLTComponentDataType GetOutputDataType();
77         virtual int GetOutputDataTypes(AliHLTComponentDataTypeList& tgtList);
78         virtual void GetOutputDataSize(unsigned long& constBase, double& inputMultiplier);
79
80         virtual AliHLTComponent* Spawn();
81
82 protected:
83
84         virtual int DoInit(int argc, const char** argv);
85         virtual int DoDeinit();
86         virtual int DoEvent(const AliHLTComponentEventData& evtData, AliHLTComponentTriggerData& trigData);
87         virtual bool IgnoreArgument(const char* arg) const;
88         using AliHLTProcessor::DoEvent;
89         
90 private:
91
92         // Prevent copying of these objects.
93         AliHLTMUONRootifierComponent(const AliHLTMUONRootifierComponent& /*object*/);
94         AliHLTMUONRootifierComponent& operator = (const AliHLTMUONRootifierComponent& /*object*/);
95         
96         bool fWarnForUnexpecedBlock;  /// Flag indicating if we should log a warning if we got a block of an unexpected type.
97
98         ClassDef(AliHLTMUONRootifierComponent, 0); // Converter component of dHLT raw data.
99 };
100
101 #endif // ALIHLTMUONROOTIFIERCOMPONENT_H