3 #ifndef ALIHLTHOMERBLOCKDESC_H
4 #define ALIHLTHOMERBLOCKDESC_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 */
10 /** @file AliHLTHOMERBlockDesc.h
11 @author Jochen Thaeder
13 @brief Container for HOMER Blocks
16 // see below for class documentation
18 // refer to README to build package
20 // visit http://web.ift.uib.no/~kjeks/doc/alice-hlt
27 #include "AliHLTLoggingVariadicFree.h"
30 * @class AliHLTHOMERBlockDesc
31 * This class contains the data which comes from 1 block, delivered via the
32 * HOMER interface. It used in order to fill these block in TLists. ( It has
33 * to inherit from TObject ). Further more it reads the specification of the
34 * block and classifies the data as TObject, raw data, or something else. Mainly
35 * used in the AliEVEHOMERManager, as data objects for AliEVE.
37 * @ingroup alihlt_homer
39 class AliHLTHOMERBlockDesc : public TObject, public AliHLTLogging {
44 * ---------------------------------------------------------------------------------
45 * Constructor / Destructor
46 * ---------------------------------------------------------------------------------
49 /** standard constructor */
50 AliHLTHOMERBlockDesc();
53 virtual ~AliHLTHOMERBlockDesc();
56 * ---------------------------------------------------------------------------------
57 * Data Handling - Setter - public
58 * ---------------------------------------------------------------------------------
62 * @param data Pointer to data
63 * @param size Size of data
64 * @param origin Detector
65 * @param dataType HLT data type
66 * @param specification HLT specification
68 void SetBlock( void * data, ULong_t size, TString origin, TString dataType, ULong_t specification );
71 * ---------------------------------------------------------------------------------
72 * TObject Handling - public
73 * ---------------------------------------------------------------------------------
76 /** Returns if block contains a TObject
77 * @return Returns kTRUE if block contains a TObject, kFALSE otherwise.
79 Bool_t IsTObject() { return fIsTObject;}
81 /** Returns Pointer to TObject */
82 TObject* GetTObject() { return fTObject; }
84 /** Get class name of this block
87 TString GetClassName() { return fClassName; }
90 * ---------------------------------------------------------------------------------
91 * Data Handling - Getter - public
92 * ---------------------------------------------------------------------------------
95 /** Returns if block contains a raw data, fClassName is not set in this case.
96 * @return Returns kTRUE if block contains raw data, kFALSE otherwise.
98 Bool_t IsRawData() { return fIsRawData;}
100 /** Get pointer to data
101 * @return Pointer to data
103 void* GetData() { return fData; }
106 * @return Size of data
108 ULong_t GetSize() { return fSize; }
110 /** Get name of this block
113 TString GetBlockName() { return fBlockName; }
115 /** Get detector of this block
116 * @return Detector name
118 TString GetDetector() { return fDetector; }
120 /** Get HLT data type of this block
121 * @return HLT data type
123 TString GetDataType() { return fDataType; }
125 /** Get HLT specification of this block
126 * @return HLT specification
128 ULong_t GetSpecification() { return fSpecification; }
130 /** Get sub detector of this block
131 * @return subdetector
133 Int_t GetSubDetector() { return fSubDetector; }
135 /** Get sub sub detector of this block
136 * @return subsubdetector
138 Int_t GetSubSubDetector() { return fSubSubDetector; }
140 /** Returns kTRUE if HLT specification indicates a subdetector range
141 * @return kTRUE if subdetector range
143 Bool_t HasSubDetectorRange() { return fHasSubDetectorRange; }
145 /** Returns kTRUE if HLT specification indicates a subsubdetector range
146 * @return kTRUE if subsubdetector range
148 Bool_t HasSubSubDetectorRange(){ return fHasSubSubDetectorRange; }
150 ///////////////////////////////////////////////////////////////////////////////////
154 /** copy constructor prohibited */
155 AliHLTHOMERBlockDesc(const AliHLTHOMERBlockDesc&);
157 /** assignment operator prohibited */
158 AliHLTHOMERBlockDesc& operator=(const AliHLTHOMERBlockDesc&);
161 * ---------------------------------------------------------------------------------
162 * Data Handling - private
163 * ---------------------------------------------------------------------------------
166 /** Set all additional members*/
167 void SetBlockParameters();
169 /** Checks if Block contains a TObject.
170 * If so, set fIsTObject to kTRUE, otherwise kFALSE
173 Bool_t CheckIfTObject();
175 /** Checks if Block contains a TObject raw data.
176 * If so, set fIsRawData to kTRUE, otherwise kFALSE
179 Bool_t CheckIfRawData();
182 * ---------------------------------------------------------------------------------
184 * ---------------------------------------------------------------------------------
187 // -- Block properties --
188 // ----------------------
190 /** Pointer to data of the block */
194 ULong_t fSize; // see above
197 TString fBlockName; // see above
202 /** States if block contains a TObject */
203 Bool_t fIsTObject; // see above
205 /** States if block contains a raw data */
206 Bool_t fIsRawData; // see above
208 // -- TObject properties --
209 // ------------------------
211 /** AliHTMessage object containg a TObject */
212 AliHLTMessage* fMessage; //
214 /** TObject extracted out of @see AliHLTMessage */
215 TObject* fTObject; //
217 /** Class Name of the block */
218 TString fClassName; // see above
220 // -- Data Specifications --
221 // -------------------------
224 TString fDataType; // see above
226 /** Detector Name, e.g. PHOS */
227 TString fDetector; // see above
229 /** HLT Specification */
230 ULong_t fSpecification; // see above
232 // XXXXXXXXXXXXXXXXXXXXXXXX REMOVE IF NOT NEEDED XXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
234 // -- Sub Detector Specifications --
235 // ---------------------------------
237 /** SubDetector Name e.g. MODULE */
238 Int_t fSubDetector; // see above
240 /** SubSubDetector Name e.g. PARTITION */
241 Int_t fSubSubDetector; // see above
243 /** States id block has a subdetector range */
244 Bool_t fHasSubDetectorRange; // see above
246 /** States id block has a subsubdetector range */
247 Bool_t fHasSubSubDetectorRange; // see above
249 // XXXXXXXXXXXXXXXXXXXXXXXX REMOVE IF NOT NEEDED XXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
251 ClassDef( AliHLTHOMERBlockDesc, 2 )