]> git.uio.no Git - u/mrichter/AliRoot.git/blob - HLT/MUON/OfflineInterface/AliHLTMUONRootifierComponent.h
Fixing coding violations and getting rid of warnings.
[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   
13  * @brief  Component for converting dHLT raw data into ROOT objects.
14  */
15
16 #include "AliHLTProcessor.h"
17
18 // Temporary solution for grouping together objects for the same event.
19 #include "TObjArray.h"
20
21 class AliHLTMUONEvent : public TObject
22 {
23 public:
24
25         AliHLTMUONEvent(AliHLTEventID_t eventId = AliHLTEventID_t(-1))
26                 : fEventId(eventId)
27         {
28                 fArray.SetOwner(kTRUE);
29         }
30         
31         virtual ~AliHLTMUONEvent() {}
32         
33         AliHLTEventID_t EventID() const { return fEventId; }
34         const TObjArray& Array() const { return fArray; }
35         
36         // Takes ownership of the object.
37         void Add(TObject* obj) { fArray.Add(obj); }
38         
39         virtual void Print(Option_t* option = NULL) const;
40
41 private:
42
43         AliHLTEventID_t fEventId;  // The event ID.
44         TObjArray fArray;          // Array of event objects.
45         
46         ClassDef(AliHLTMUONEvent, 1); // Container class for dHLT event results.
47 };
48
49
50 /**
51  * Converts dHLT raw data blocks into ROOT objects.
52  */
53 class AliHLTMUONRootifierComponent : public AliHLTProcessor
54 {
55 public:
56
57         AliHLTMUONRootifierComponent();
58         virtual ~AliHLTMUONRootifierComponent();
59         
60         virtual const char* GetComponentID();
61
62         virtual void GetInputDataTypes(vector<AliHLTComponentDataType>& list);
63         virtual AliHLTComponentDataType GetOutputDataType();
64
65         virtual void GetOutputDataSize(unsigned long& constBase, double& inputMultiplier);
66
67         virtual AliHLTComponent* Spawn();
68
69 protected:
70
71         virtual int DoInit(int argc, const char** argv);
72         virtual int DoDeinit();
73         virtual int DoEvent(const AliHLTComponentEventData& evtData, AliHLTComponentTriggerData& trigData);
74         using AliHLTProcessor::DoEvent;
75         
76 private:
77
78         // Prevent copying of these objects.
79         AliHLTMUONRootifierComponent(const AliHLTMUONRootifierComponent& /*object*/);
80         AliHLTMUONRootifierComponent& operator = (const AliHLTMUONRootifierComponent& /*object*/);
81
82         ClassDef(AliHLTMUONRootifierComponent, 0); // Converter component of dHLT raw data.
83 };
84
85 #endif // ALIHLTMUONROOTIFIERCOMPONENT_H