]> git.uio.no Git - u/mrichter/AliRoot.git/blob - HLT/TRD/AliHLTTRDEsdWriterComponent.h
HLTcalo module
[u/mrichter/AliRoot.git] / HLT / TRD / AliHLTTRDEsdWriterComponent.h
1 //-*- Mode: C++ -*-
2 // $Id$
3
4 #ifndef ALIHLTTRDESDWRITERCOMPONENT_H
5 #define ALIHLTTRDESDWRITERCOMPONENT_H
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   AliHLTTRDEsdWriterComponent.h
11     @author Mateusz Ploskon
12     @date   
13     @brief  Writer component to store tracks of the HLT TRD 
14
15                                                                           */
16 #include "AliHLTRootFileWriterComponent.h"
17
18 // forward declarations
19 class TTree;
20 class AliESDEvent;
21 class AliESDfriend;
22 class TClonesArray;
23 /**
24  * @class AliHLTTRDEsdWriterComponent
25  * @see AliHLTFileWriter and AliHLTRootFileWriterComponent for more parameters
26  */
27 class AliHLTTRDEsdWriterComponent : public AliHLTRootFileWriterComponent
28 {
29  public:
30   /** standard constructor */
31   AliHLTTRDEsdWriterComponent();
32   /** destructor */
33   ~AliHLTTRDEsdWriterComponent();
34
35   /**
36    * The id of the component.
37    * @return component id (string)
38    */
39   const char* GetComponentID() {return "TRDEsdWriter";};
40
41   void GetInputDataTypes( vector<AliHLTComponent_DataType>& list);
42
43   /**
44    * Spawn function.
45    * @return new class instance
46    */
47   //virtual void GetOutputDataSize( unsigned long& constBase, double& inputMultiplier );
48   AliHLTComponent* Spawn() {return new AliHLTTRDEsdWriterComponent;}
49
50  protected:
51   /**
52    * Init the writer.
53    * The DoInit function is not available for this child class. InitWriter is the
54    * corresponding function for classes derived from AliHLTFileWriter.
55    */
56   int InitWriter();
57
58   /**
59    * Init the writer.
60    * The DoDeinit function is not available for this child class. CloseWriter is the
61    * corresponding function for classes derived from AliHLTFileWriter.
62    */
63   int CloseWriter();
64
65   /**
66    * Data processing method for the component.
67    * The function can be overloaded by specific ROOT file writer
68    * components.
69    * @param evtData       event data structure
70    * @param blocks        input data block descriptors
71    * @param trigData      trigger data structure
72    */
73   virtual int DumpEvent( const AliHLTComponentEventData& evtData,
74                          const AliHLTComponentBlockData* blocks, 
75                          AliHLTComponentTriggerData& trigData );
76                          
77   using AliHLTRootFileWriterComponent::DumpEvent;
78   /**
79    * Scan one argument and adjacent parameters.
80    * @param argc           size of the argument array
81    * @param argv           agument array for component initialization
82    * @return number of processed members of the argv <br>
83    *         -EINVAL unknown argument <br>
84    *         -EPROTO parameter for argument missing <br>
85    */
86   //int ScanArgument(int argc, const char** argv);
87
88  private:
89   /** not a valid copy constructor, defined according to effective C++ style */
90   AliHLTTRDEsdWriterComponent(const AliHLTTRDEsdWriterComponent&);
91   /** not a valid assignment op, but defined according to effective C++ style */
92   AliHLTTRDEsdWriterComponent& operator=(const AliHLTTRDEsdWriterComponent&);
93
94   /** the ESD tree */
95   TTree* fTree; //! transient value
96   TTree* fFrTree; //! transient value
97   
98   /** the ESD */
99   AliESDEvent* fESD; //! transient value
100   AliESDfriend* fESDfriend; //! transient value
101   TFile* fFile; //! transient value
102   TFile* fFrFile; //! transient value
103   TClonesArray* fTracksArray; //! transient value
104
105   ClassDef(AliHLTTRDEsdWriterComponent, 1)
106
107 };
108 #endif