Using common HLT track data format for TRD tracks (Theodor)
[u/mrichter/AliRoot.git] / HLT / global / AliHLTGlobalEsdConverterComponent.h
CommitLineData
a1408c4b 1//-*- Mode: C++ -*-
2// $Id$
3#ifndef ALIHLTGLOBALESDCONVERTERCOMPONENT_H
4#define ALIHLTGLOBALESDCONVERTERCOMPONENT_H
5//* This file is property of and copyright by the ALICE HLT Project *
6//* ALICE Experiment at CERN, All rights reserved. *
7//* See cxx source for full Copyright notice *
8
9/** @file AliHLTGlobalEsdConverterComponent.h
10 @author Matthias Richter
11 @date
12 @brief Global ESD converter component.
13*/
14
15#include "AliHLTProcessor.h"
16#include <vector>
17
18// forward declarations
19class AliESDEvent;
20class TTree;
21struct AliHLTTracksData;
22
23/**
24 * @class AliHLTGlobalEsdConverterComponent
25 * Global collector for information designated for the HLT ESD.
26 *
27 * componentid: \b GlobalEsdConverter <br>
28 * componentlibrary: \b libAliHLTGlobal.so <br>
29 * Arguments: <br>
30 * <!-- NOTE: ignore the \li. <i> and </i>: it's just doxygen formatting -->
31 * \li -notree <br>
32 * write ESD directly to output (::kAliHLTDataTypeESDObject)
33 * this has been made the default behavior in Sep 2008.
34 * \li -tree <br>
35 * write ESD directly to TTree and to output (::kAliHLTDataTypeESDTree)
36 *
37 * @ingroup alihlt_tpc_components
38 */
39class AliHLTGlobalEsdConverterComponent : public AliHLTProcessor
40{
41 public:
42 /** standard constructor */
43 AliHLTGlobalEsdConverterComponent();
44 /** destructor */
18ada816 45 virtual ~AliHLTGlobalEsdConverterComponent();
a1408c4b 46
47 // interface methods of base class
48 const char* GetComponentID() {return "GlobalEsdConverter";};
49 void GetInputDataTypes(AliHLTComponentDataTypeList& list);
50 AliHLTComponentDataType GetOutputDataType();
51 void GetOutputDataSize(unsigned long& constBase, double& inputMultiplier);
52 AliHLTComponent* Spawn() {return new AliHLTGlobalEsdConverterComponent;}
53
54 protected:
55 // interface methods of base class
56 int DoInit(int argc, const char** argv);
57 int DoDeinit();
58 int DoEvent( const AliHLTComponentEventData& evtData,
59 AliHLTComponentTriggerData& trigData);
60
61 using AliHLTProcessor::DoEvent;
62
63 /**
64 * Process the input data blocks.
65 * @param pTree tree to be filled
66 * @param pESD ESD to be filled
67 * @return neg. error code if failed
68 */
69 int ProcessBlocks(TTree* pTree, AliESDEvent* pESD);
70
71 private:
72 /** copy constructor prohibited */
73 AliHLTGlobalEsdConverterComponent(const AliHLTGlobalEsdConverterComponent&);
74 /** assignment operator prohibited */
75 AliHLTGlobalEsdConverterComponent& operator=(const AliHLTGlobalEsdConverterComponent&);
76
77 /**
78 * (Re)Configure from the CDB
79 * Loads the following objects:
80 * - HLT/ConfigHLT/SolenoidBz
81 */
82 int Reconfigure(const char* cdbEntry, const char* chainId);
83
84 /**
85 * Configure the component.
86 * Parse a string for the configuration arguments and set the component
87 * properties.
88 */
89 int Configure(const char* arguments);
90
a1408c4b 91 /// write object to TTree or directly
92 int fWriteTree; //!transient
93
093b64dc 94 /// verbosity level
95 int fVerbosity; //!transient
96
18ada816 97protected:
98
99 /// the ESD
100 AliESDEvent* fESD; //! transient value
101
102 /// solenoid b field
103 Double_t fSolenoidBz; //! transient
104
a1408c4b 105 ClassDef(AliHLTGlobalEsdConverterComponent, 0)
106};
107#endif