]> git.uio.no Git - u/mrichter/AliRoot.git/blob - HLT/BASE/AliHLTDataTypes.h
b3c167cfc0806863e510f3adb529210bc5597dcf
[u/mrichter/AliRoot.git] / HLT / BASE / AliHLTDataTypes.h
1 // @(#) $Id$
2
3 #ifndef ALIHLTDATATYPES_H
4 #define ALIHLTDATATYPES_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   AliHLTDataTypes.h
10     @author Matthias Richter, Timm Steinbeck, Jochen Thaeder
11     @date   
12     @brief  Data type declaration for the HLT module.
13 */
14
15 //////////////////////////////////////////////////////////////////////////
16 //
17 // version no of HLT data types
18 //
19 //////////////////////////////////////////////////////////////////////////
20
21 /* Version   Description
22  *   1       first version until June 07; implicite, not tagged
23  *   2       introduced June 07, enhanced/cleaned/arranged structure
24  *   3       2007-11-15 RAW DDL data type added; some inconsistencies fixed
25  *           ('void' and 'any' origins); added signed HLT basic data types
26  *           2007-11-23 origin defines have become variables in conjunction
27  *           to be used with the operator| (AliHLTComponentDataType)
28  *           2007-11-24 added trigger structs and ESD tree data type
29  *   4       Component configuration and DCS update events added
30  *           gkAliHLTDDLListSize set from 29 to 30 according to new PubSub
31  *           specs
32  *   5       Data types for Run and Event summary, and for monitoring added
33  *   6       Common data types for TreeD and TreeR defined
34  *           kAliHLTAllDataTypes and kAliHLTDataOriginSample added
35  *           kAliHLTDataOriginEMCAL added
36  *           kAliHLTDataTypeRunType added
37  *   7       kAliHLTDataTypeComponentStatistics, kAliHLTDataTypeComponentTable,
38  *           and AliHLTComponentStatistics have been added for optional
39  *           component block statistics
40  *   8       new wrapper interface has been introduced, old wrapper interface
41  *           deprecated but kept for backward compatibility, the PubSub
42  *           interface is going to be compiled independently of AliHLT, new
43  *           interface provided by the libHLTinterface.so
44  *           AliHLTComponentEnvironment -> AliHLTAnalysisEnvironment
45  *   9       added data types for arrays of AliHLTExternalTrackParam sets and
46  *           TClonesArrays of AliExternalTrackParam objects.
47  *  10       Changes for information objects neededfor running with offline
48  *           chains and analysis tasks.
49  *           kAliHLTMCObjectDataType added
50  *           kAliHLTDataOriginOffline added
51  *           kAliHLTDataOriginHLT added
52  *  11       extended AliHLTComponentStatistics: one more member to store the
53  *           cycle time between events per component.
54  *  12       added common data type id 'CLUSTERS'
55  *           added data type 'ECSPARAM' for the full ECS parameter string to
56  *           be sebt during SOR
57  */
58 #define ALIHLT_DATA_TYPES_VERSION 12
59
60 //////////////////////////////////////////////////////////////////////////
61 //
62 // HLT data origin variables.
63 //
64 // By converting from defines to variables, the origins can be used with
65 // the operator|
66 //
67 // AliHLTComponentDataType dt;
68 // dt = kAliHLTDataTypeDDLRaw | kAliHLTDataOriginTPC;
69 //
70 //////////////////////////////////////////////////////////////////////////
71
72 /** field size of datat type origin 
73  * @ingroup alihlt_component_datatypes
74  */
75 const int kAliHLTComponentDataTypefOriginSize=4;
76
77
78 /** invalid data origin 
79  * @ingroup alihlt_component_datatypes
80  */
81 # define kAliHLTDataOriginVoid "\0\0\0"
82 /** old invalid data origin, kept for backward compatibility */
83 # define kAliHLTVoidDataOrigin "\0\0\0"
84
85 /** wildcard data type origin 
86  * @ingroup alihlt_component_datatypes
87  */
88 # define kAliHLTDataOriginAny "***"
89 /** old wildcard data type origin, kept for backward compatibility */
90 # define kAliHLTAnyDataOrigin "***"
91
92 /** Data origin HLT out 
93  * @ingroup alihlt_component_datatypes
94  */
95 extern const char kAliHLTDataOriginOut[kAliHLTComponentDataTypefOriginSize];
96
97 /** Data origin HLT, used for HLT specifc data 
98  *  in offline chains. This not a bug!
99  * @ingroup alihlt_component_datatypes
100  */
101 extern const char kAliHLTDataOriginHLT[kAliHLTComponentDataTypefOriginSize];
102
103 /** Data origin Offline 
104  * @ingroup alihlt_component_datatypes
105  */
106 extern const char kAliHLTDataOriginOffline[kAliHLTComponentDataTypefOriginSize];
107
108 /** Data origin HLT/PubSub private internal 
109  * @ingroup alihlt_component_datatypes
110  */
111 extern const char kAliHLTDataOriginPrivate[kAliHLTComponentDataTypefOriginSize];
112
113 /** Data origin TPC 
114  * @ingroup alihlt_component_datatypes
115  */
116 extern const char kAliHLTDataOriginTPC[kAliHLTComponentDataTypefOriginSize];
117
118 /** Data origin PHOS 
119  * @ingroup alihlt_component_datatypes
120  */
121 extern const char kAliHLTDataOriginPHOS[kAliHLTComponentDataTypefOriginSize];
122
123 /** Data origin FMD
124  * @ingroup alihlt_component_datatypes
125  */
126 extern const char kAliHLTDataOriginFMD[kAliHLTComponentDataTypefOriginSize];
127
128 /** Data origin MUON 
129  * @ingroup alihlt_component_datatypes
130  */
131 extern const char kAliHLTDataOriginMUON[kAliHLTComponentDataTypefOriginSize];
132
133 /** Data origin TRD 
134  * @ingroup alihlt_component_datatypes
135  */
136 extern const char kAliHLTDataOriginTRD[kAliHLTComponentDataTypefOriginSize];
137
138 /** Data origin ITS 
139  * @ingroup alihlt_component_datatypes
140  */
141 extern const char kAliHLTDataOriginITS[kAliHLTComponentDataTypefOriginSize];
142
143 /** Data origin ITS SPD
144  * @ingroup alihlt_component_datatypes
145  */
146 extern const char kAliHLTDataOriginITSSPD[kAliHLTComponentDataTypefOriginSize];
147
148 /** Data origin ITS SDD
149  * @ingroup alihlt_component_datatypes
150  */
151 extern const char kAliHLTDataOriginITSSDD[kAliHLTComponentDataTypefOriginSize];
152
153 /** Data origin ITS SSD
154  * @ingroup alihlt_component_datatypes
155  */
156 extern const char kAliHLTDataOriginITSSSD[kAliHLTComponentDataTypefOriginSize];
157
158 /** Data origin for examples 
159  * @ingroup alihlt_component_datatypes
160  */
161 extern const char kAliHLTDataOriginSample[kAliHLTComponentDataTypefOriginSize];
162
163 /** Data origin EMCAL 
164  * @ingroup alihlt_component_datatypes
165  */
166 extern const char kAliHLTDataOriginEMCAL[kAliHLTComponentDataTypefOriginSize];
167
168 //////////////////////////////////////////////////////////////////////////
169 //
170 // HLT common data type defines
171 //
172 //////////////////////////////////////////////////////////////////////////
173
174 /** field size of data type id 
175  * @ingroup alihlt_component_datatypes
176  */
177 const int kAliHLTComponentDataTypefIDsize=8;
178
179
180 /** invalid data type id 
181  * @ingroup alihlt_component_datatypes
182  */
183 # define kAliHLTVoidDataTypeID "\0\0\0\0\0\0\0"
184
185 /** special id for all data types: any + void
186  * @ingroup alihlt_component_datatypes
187  */
188 # define kAliHLTAllDataTypesID "ALLDATA"
189
190 /** special id for any valid data type id
191  * @ingroup alihlt_component_datatypes
192  */
193 # define kAliHLTAnyDataTypeID "*******"
194
195 /** DDL RAW data 
196  * @ingroup alihlt_component_datatypes
197  */
198 # define kAliHLTDDLRawDataTypeID   {'D','D','L','_','R','A','W',' '}
199
200 /** CLUSTERS data
201  * Common data type for the output of cluster finders, the exact
202  * format depends on the origin (detector)
203  * @ingroup alihlt_component_datatypes
204  */
205 # define kAliHLTClustersDataTypeID {'C','L','U','S','T','E','R','S'}
206
207 /** calibration data for file exchange subscriber 
208  * @ingroup alihlt_component_datatypes
209  */
210 # define kAliHLTFXSCalibDataTypeID {'F','X','S','_','C','A','L',' '}
211
212 /** start of run (SOR) event 
213  * @ref AliHLTRunDesc
214  * @ingroup alihlt_component_datatypes
215  */
216 # define kAliHLTSORDataTypeID      {'S','T','A','R','T','O','F','R'}
217
218 /** end of run (EOR) event 
219  * @ref AliHLTRunDesc
220  * @ingroup alihlt_component_datatypes
221  */
222 # define kAliHLTEORDataTypeID      {'E','N','D','O','F','R','U','N'}
223
224 /** run type data block
225  * string with run type as payload
226  * @ingroup alihlt_component_datatypes
227  */
228 # define kAliHLTRunTypeDataTypeID  {'R','U','N','T','Y','P','E',' '}
229
230 /** DDL list event 
231  * @ref AliHLTEventDDL
232  * @ingroup alihlt_component_datatypes
233  */
234 # define kAliHLTDDLDataTypeID      {'D','D','L','L','I','S','T',' '}
235
236 /** EventType event 
237  * - empty payload, specification gives eventType
238  * @ingroup alihlt_component_datatypes
239  */
240 # define kAliHLTEventDataTypeID    {'E','V','E','N','T','T','Y','P'}
241
242 /** ECS parameter event 
243  * - sent during the SOR event by the framework
244  * - contains the full ECS parameter string
245  * @ingroup alihlt_component_datatypes
246  */
247 # define kAliHLTECSParamDataTypeID {'E','C','S','P','A','R','A','M'}
248
249 /** ComponentConfiguration event
250  * - payload contains the CDB path as string
251  * @ingroup alihlt_component_datatypes
252  */
253 # define kAliHLTComConfDataTypeID  {'C','O','M','_','C','O','N','F'}
254
255 /** DCS value update event
256  * - payload contains string of relevant detectors
257  * @ingroup alihlt_component_datatypes
258  */
259 # define kAliHLTUpdtDCSDataTypeID  {'U','P','D','T','_','D','C','S'}
260
261 /** MC data block
262  * an AliMCEvent object of varying origin
263  * The 'V0' at the end allows a versioning
264  * @ingroup alihlt_component_datatypes
265  */
266 # define kAliHLTMCObjectDataTypeID    {'A','L','I','M','C','_','V','0'}
267
268 /** ESD data block
269  * an AliESD object of varying origin
270  * The 'V0' at the end allows a versioning
271  * @ingroup alihlt_component_datatypes
272  */
273 # define kAliHLTESDObjectDataTypeID    {'A','L','I','E','S','D','V','0'}
274
275 /** ESD tree data block
276  * TTree with an AliESD object of varying origin
277  * @ingroup alihlt_component_datatypes
278  */
279 # define kAliHLTESDTreeDataTypeID      {'E','S','D','_','T','R','E','E'}
280
281 /** AliRoot TreeD
282  * - the digits tree of an AliRoot module
283  * @ingroup alihlt_component_datatypes
284  */
285 #define kAliHLTTreeDDataTypeID         {'A','L','I','T','R','E','E','D'}
286
287 /** AliRoot TreeR
288  * - the rec points tree of an AliRoot module
289  * @ingroup alihlt_component_datatypes
290  */
291 #define kAliHLTTreeRDataTypeID         {'A','L','I','T','R','E','E','R'}
292
293 /** HW Address selection data block
294  * - a selection list for 16 bit HW addresses
295  * - varying origin
296  * @ingroup alihlt_component_datatypes
297  */
298 # define kAliHLTHwAddr16DataTypeID     {'H','W','A','D','D','R','1','6'}
299
300 /** Event Statistics
301  * - event statistics for given detectors
302  * - varying origin
303  * @ingroup alihlt_component_datatypes
304  */
305 # define kAliHLTEventStatisticsDataTypeID     {'E','V','_','S','T','A','T','I'}
306
307 /** Event Summary
308  * - event summary
309  * - origin : kAliHLTDataOriginOut ( HLT )
310  * @ingroup alihlt_component_datatypes
311  */
312 # define kAliHLTEventSummaryDataTypeID        {'E','V','_','S','U','M','M','A'}
313
314 /** Run Statistics
315  * - run statistics for given detectors
316  * - varying origin
317  * @ingroup alihlt_component_datatypes
318  */
319 # define kAliHLTRunStatisticsDataTypeID       {'R','U','N','S','T','A','T','I'}
320
321 /** Run Summary
322  * - run summary
323  * - origin : kAliHLTDataOriginOut ( HLT )
324  * @ingroup alihlt_component_datatypes
325  */
326 # define kAliHLTRunSummaryDataTypeID          {'R','U','N','S','U','M','M','A'}
327
328 /** Block Statistics
329  * - small block statistics info added to the data stream by
330  *   the component base class
331  * - origin kAliHLTDataOriginPrivate
332  * @ingroup alihlt_component_datatypes
333  */
334 # define kAliHLTComponentStatisticsDataTypeID {'C','O','M','P','S','T','A','T'}
335
336 /** Component table
337  * - list of components in the chain to be percolated through the chain
338  * - each component adds it's chain id string and a generated 32bit id
339  * @ingroup alihlt_component_datatypes
340  */
341 # define kAliHLTComponentTableDataTypeID      {'C','O','M','P','T','A','B','L'}
342
343 /** general ROOT TObject
344  * - a general TObject exported from the HLT analysis
345  * - varying origin
346  * @ingroup alihlt_component_datatypes
347  */
348 #define kAliHLTTObjectDataTypeID              {'R','O','O','T','T','O','B','J'}
349
350 /** ROOT TObjArray
351  * - a TObjArray exported from the HLT analysis
352  * - varying origin
353  * @ingroup alihlt_component_datatypes
354  */
355 #define kAliHLTTObjArrayDataTypeID            {'R','O','O','T','O','B','A','R'}
356
357 /** ROOT TTree
358  * - a TTree object exported from the HLT analysis
359  * - varying origin
360  * @ingroup alihlt_component_datatypes
361  */
362 #define kAliHLTTTreeDataTypeID                {'R','O','O','T','T','R','E','E'}
363
364 /** ROOT histogram
365  * - a histogram object exported from the HLT analysis
366  * - class derives from TH1 (directly or indirectly) and inherits all common functionality
367  * - varying origin
368  * @ingroup alihlt_component_datatypes
369  */
370 #define kAliHLTHistogramDataTypeID            {'R','O','O','T','H','I','S','T'}
371
372 /** ROOT TNtuple
373  * - a TNtupl object exported from the HLT analysis
374  * - varying origin
375  * @ingroup alihlt_component_datatypes
376  */
377 #define kAliHLTTNtupleDataTypeID              {'R','O','O','T','T','U','P','L'}
378
379 /** HLT Track
380  * - Struct for Tracks based on AliExternalTrackParam
381  * - varying origin
382  * @ingroup alihlt_component_datatypes
383  */
384 #define kAliHLTTrackDataTypeID                {'H','L','T','T','R','A','C','K'}
385
386 /** TClonesArray of AliExternalTrackParam
387  * @ingroup alihlt_component_datatypes
388  */
389 #define kAliHLTExternalTrackParamDataTypeID   {'T','C','A','E','X','T','T','R'}
390
391 /** HLT Jet
392  * - Struct for jets based on AliHLTJETJets
393  * - varying origin
394  * @ingroup alihlt_component_datatypes
395  */
396 #define kAliHLTJetDataTypeID                  {'H','L','T','J','E','T','V','0'}
397
398 using namespace std;
399
400 extern "C" {
401   //////////////////////////////////////////////////////////////////////////
402   //
403   // Basic HLT data types
404   //
405   //////////////////////////////////////////////////////////////////////////
406
407   typedef unsigned char AliHLTUInt8_t;
408
409   typedef signed char AliHLTInt8_t;
410
411   typedef unsigned short AliHLTUInt16_t;
412
413   typedef signed short AliHLTInt16_t;
414
415   typedef unsigned int AliHLTUInt32_t;
416
417   typedef signed int AliHLTInt32_t;
418
419   typedef unsigned long long AliHLTUInt64_t;
420
421   typedef signed long long AliHLTInt64_t;
422
423   typedef float AliHLTFloat32_t;
424
425   typedef double AliHLTFloat64_t;
426
427   typedef AliHLTUInt64_t AliHLTEventID_t;
428
429   //////////////////////////////////////////////////////////////////////////
430   //
431   // HLT logging levels
432   //
433   //////////////////////////////////////////////////////////////////////////
434
435   /**
436    * Logging severities of the HLT
437    */
438   enum AliHLTComponentLogSeverity {
439     /** no logging */
440     kHLTLogNone      = 0,
441     /** benchmark messages */
442     kHLTLogBenchmark = 0x1,
443     /** debug messages */
444     kHLTLogDebug     = 0x2,
445     /** info messages */
446     kHLTLogInfo      = 0x4,
447     /** warning messages */
448     kHLTLogWarning   = 0x8,
449     /** error messages */
450     kHLTLogError     = 0x10,
451     /** fatal error messages */
452     kHLTLogFatal     = 0x20,
453     /** few important messages not to be filtered out.
454      * redirected to kHLTLogInfo in AliRoot
455      */
456     kHLTLogImportant = 0x40,
457     /** special value to enable all messages */
458     kHLTLogAll       = 0x7f,
459     /** the default logging filter */
460     kHLTLogDefault   = 0x79
461   };
462
463   //////////////////////////////////////////////////////////////////////////
464   //
465   // HLT data structures for data exchange and external interface
466   //
467   //////////////////////////////////////////////////////////////////////////
468
469   /**
470    * @struct AliHLTComponentEventData
471    * Event descriptor
472    */
473   struct AliHLTComponentEventData
474   {
475     AliHLTUInt32_t fStructSize;        /// Size of this structure in bytes.
476     AliHLTEventID_t fEventID;          /// 64 bit event ID number.
477     AliHLTUInt32_t fEventCreation_s;   /// Event creation time in seconds (Should be added to fEventCreation_us*1e6).
478     AliHLTUInt32_t fEventCreation_us;  /// Fractional event creation time in micro seconds.
479     AliHLTUInt32_t fBlockCnt;          /// The number of raw data blocks received by the component.
480   };
481
482   /**
483    * @struct AliHLTComponentShmData
484    * Shared memory descriptor.
485    * Irrelevant for analysis components.
486    */
487   struct AliHLTComponentShmData
488   {
489     AliHLTUInt32_t fStructSize;  /// Size of this structure in bytes.
490     AliHLTUInt32_t fShmType;     /// The type code of the shared memory.
491     AliHLTUInt64_t fShmID;       /// The shared memory identifier.
492   };
493
494   /**
495    * @defgroup alihlt_component_datatypes Common Component Data Types
496    * The analysis framework defines a number of common data types for
497    * usage in the detector modules, like e.g. ::kAliHLTAnyDataType
498    * and ::kAliHLTDataTypeDDLRaw. Those data types always have
499    * origin ::kAliHLTDataOriginAny. The correct detector origin can be
500    * set by using operator '|'
501    * <pre>
502    * AliHLTComponentDataType dt=kAliHLTDDLRawDataTypeID|kAliHLTDataOriginTPC
503    * </pre>
504    * @ingroup alihlt_component
505    */
506
507   /**
508    * @struct AliHLTComponentDataType
509    * Data type descriptor for data blocks transferred through the processing
510    * chain.
511    * @ingroup alihlt_component_datatypes
512    */
513   struct AliHLTComponentDataType
514   {
515     AliHLTUInt32_t fStructSize;                            /// Size of this structure in bytes.
516     char fID[kAliHLTComponentDataTypefIDsize];             /// Data type identifier.
517     char fOrigin[kAliHLTComponentDataTypefOriginSize];     /// Subsystem or detector origin of the data.
518   };
519
520   /**
521    * @struct AliHLTComponentBlockData
522    * This is the decription of data blocks exchanged between components.
523    * \b IMPORTANT: The validity of fPtr and fOffset is different for input and
524    * output blocks:
525    * - input blocks: The \em fPtr member always points to the beginning of the data
526    *                 of size \em fSize. fOffset is ignored and should be in most
527    *                 case 0.
528    * - output blocks: The \em fPtr member is ignored by the framework. \em fOffset
529    *                  must specify the start of the data relative to the output
530    *                  buffer. The data block has size \em fSize.
531    */
532   struct AliHLTComponentBlockData
533   {
534     /** size and version of the struct */
535     AliHLTUInt32_t fStructSize;
536     /** shared memory key, ignored by processing components */
537     AliHLTComponentShmData fShmKey;
538     /** offset of output data relative to the output buffer */
539     AliHLTUInt32_t fOffset;
540     /** start of the data for input data blocks, fOffset to be ignored*/
541     void* fPtr;
542     /** size of the data block */
543     AliHLTUInt32_t fSize;
544     /** data type of the data block */
545     AliHLTComponentDataType fDataType;
546     /** data specification of the data block */
547     AliHLTUInt32_t fSpecification;
548   };
549
550   /**
551    * @struct AliHLTComponentEventDoneData
552    * 
553    */
554   struct AliHLTComponentEventDoneData
555   {
556     AliHLTUInt32_t fStructSize;   /// Size of this structure in bytes.
557     AliHLTUInt32_t fDataSize;     /// Size of the data section (following this data member) in bytes.
558     void* fData;                  /// Start of the data section.
559   };
560
561   /**
562    * @struct AliHLTRunDesc
563    * Event descriptor.
564    * The struct is sent with the SOR and EOR events.
565    *
566    * @note
567    * The name of the member fRunType is a bit misleading. This is not
568    * the ALICE Run Type given by the ECS to the sub-system. The member
569    * is an internal HLT run type and a combination of the HLT running
570    * mode and the beam type.
571    * <pre>
572    * Bit 0-2:   beam type identifier
573    * Bit 3-31:  HLT mode
574    * </pre>
575    */
576   struct AliHLTRunDesc
577   {
578     AliHLTUInt32_t fStructSize;   /// Size of this structure in bytes.
579     AliHLTUInt32_t fRunNo;        /// The run number for the current active run.
580     AliHLTUInt32_t fRunType;      /// The HLT run type.
581   };
582
583   /**
584    * @struct AliHLTComponentStatistics
585    * Small block size summary added by the AliHLTComponent base class
586    * if component statistics are enabled (--enable-compstat).
587    *
588    * fLevel is retrieved from incoming block statistics and incremented. 
589    * Incoming block statistics are appended to the newly added one if
590    * --enable-compstat=full has been chosen.
591    *
592    * ChangeLog:
593    *   2009-01-14 fComponentCycleTime added
594    */
595   struct AliHLTComponentStatistics
596   {
597     AliHLTUInt32_t fStructSize;           /// Size of this structure in bytes.
598     AliHLTUInt32_t fLevel;                /// Indicates from which processing stage this information is from.
599     AliHLTUInt32_t fId;                   /// Unique identifier for the chain based on CRC code.
600     AliHLTUInt32_t fTime;                 /// Real wall time used to process the data (micro seconds).
601     AliHLTUInt32_t fCTime;                /// CPU time used to process the data (micro seconds).
602     AliHLTUInt32_t fInputBlockCount;      /// Number of input data blocks.
603     AliHLTUInt32_t fTotalInputSize;       /// Total size in bytes of input data.
604     AliHLTUInt32_t fOutputBlockCount;     /// Number of output data blocks.
605     AliHLTUInt32_t fTotalOutputSize;      /// Total size in bytes of output data.
606     AliHLTUInt32_t fComponentCycleTime;   /// Real wall time indicating the start of the data processing (micro seconds).
607   };
608
609   /**
610    * @struct AliHLTComponentTableEntry
611    * Structure to be send on SOR event through the chain. Each component
612    * adds its chain id and component arguments to the list.
613    * The 'length' of the structure is variable and depends on the length
614    * of the strings in the buffer at the end.
615    *
616    * ComponentTableEntries are identified by a 32bit Id generated by a CRC
617    * algorithm from the chain Id of the component. This is not a 100% unique
618    * id but with a high probability. This approach accounts for the fact
619    * that all components are separated processes.
620    */
621   struct AliHLTComponentTableEntry
622   {
623     /** Size of this structure in bytes. */
624     AliHLTUInt32_t fStructSize;
625     /** size of the array of parent ids */
626     AliHLTUInt16_t fNofParents;
627     /** size of the description string in the appended buffer */
628     AliHLTUInt8_t  fSizeDescription;
629     /** the strings: chain id, component args, reserved */
630     AliHLTUInt8_t  fBuffer[1];
631   };
632
633   //////////////////////////////////////////////////////////////////////////
634   //
635   // Trigger meta information
636   //
637   //////////////////////////////////////////////////////////////////////////
638
639   /** field size of fAttribute */
640   const int gkAliHLTBlockDAttributeCount = 8;
641
642   /** field size of fCommonHeader */
643   const int gkAliHLTCommonHeaderCount = 8;
644
645   /** size of the DDL list */
646   const int gkAliHLTDDLListSize = 30;
647
648   /** Number of Trigger Classes of CTP in CDH */
649   const int gkNCTPTriggerClasses = 50;
650
651   /**
652    * @struct AliHLTEventDDL
653    * DDL list event.
654    * The struct is send with the DDLLIST event.
655    * Used in the trigger structure for internal apperance of 
656    * the DLLs as well as for the HLT readout list send to DAQ 
657    * ( as DataType : kAliHLTDataTypeDDL )
658    */
659   struct AliHLTEventDDL
660   {
661     AliHLTUInt32_t fCount;                       /// Indicates the number of words in fList.
662     AliHLTUInt32_t fList[gkAliHLTDDLListSize];   /// The list of DDL enable/disable bits.
663   };
664
665   /**
666    * @struct AliHLTEventTriggerData
667    */
668   struct AliHLTEventTriggerData
669   {
670     AliHLTUInt8_t  fAttributes[gkAliHLTBlockDAttributeCount];  /// List of data block attibutes.
671     AliHLTUInt64_t fHLTStatus; /// Bit field 
672     AliHLTUInt32_t fCommonHeaderWordCnt;  /// Number of words in fCommonHeader.
673     AliHLTUInt32_t fCommonHeader[gkAliHLTCommonHeaderCount];  /// The common header words.
674     AliHLTEventDDL fReadoutList;   /// The readout list structure.
675   };
676
677   /**
678    * @struct AliHLTComponentTriggerData
679    * Trigger data
680    */
681   struct AliHLTComponentTriggerData
682   {
683     AliHLTUInt32_t fStructSize;  /// Size of this structure in bytes.
684     AliHLTUInt32_t fDataSize;    /// Size of the data section (following this data member) in bytes.
685     void* fData;                 /// Start of the data section.
686   };
687
688   //////////////////////////////////////////////////////////////////////////
689   //
690   // HLT Event Type Specification
691   //
692   //////////////////////////////////////////////////////////////////////////
693
694   /** Unknown eventType specification */
695   const AliHLTUInt32_t gkAliEventTypeUnknown = ~(AliHLTUInt32_t)0;
696   /** SOR eventType specification */ 
697   const AliHLTUInt32_t gkAliEventTypeStartOfRun=1;
698   /** Data eventType specification */
699   const AliHLTUInt32_t gkAliEventTypeData=2;
700   /** EOR eventType specification */ 
701   const AliHLTUInt32_t gkAliEventTypeEndOfRun=4;
702   /** Corrupt eventType specification */
703   const AliHLTUInt32_t gkAliEventTypeCorruptID=8;
704   /** Calibration eventType specification */ 
705   const AliHLTUInt32_t gkAliEventTypeCalibration=16;
706   /** DataReplay eventType specification */
707   const AliHLTUInt32_t gkAliEventTypeDataReplay=32;
708   /** Configuration eventType specification */
709   const AliHLTUInt32_t gkAliEventTypeConfiguration=34;
710   /** Update DCS eventType specification */
711   const AliHLTUInt32_t gkAliEventTypeReadPreprocessor=35;
712   /** Tick eventType specification */ 
713   const AliHLTUInt32_t gkAliEventTypeTick=64;
714   /** Max eventType specification */ 
715   const AliHLTUInt32_t gkAliEventTypeMax=64;
716
717   //////////////////////////////////////////////////////////////////////////
718   //
719   // HLT defines and defaults
720   //
721   //////////////////////////////////////////////////////////////////////////
722
723   /** invalid event id 
724    * @ingroup alihlt_component_datatypes
725    */
726   const AliHLTEventID_t kAliHLTVoidEventID=~(AliHLTEventID_t)0;
727
728   /** invalid data specification 
729    * @ingroup alihlt_component_datatypes
730    */
731   const AliHLTUInt32_t kAliHLTVoidDataSpec = ~(AliHLTUInt32_t)0;
732
733   /** invalid run no
734    * @ingroup alihlt_component_datatypes
735    */
736   const AliHLTUInt32_t kAliHLTVoidRunNo = ~(AliHLTUInt32_t)0;
737
738   /** invalid run type
739    * @ingroup alihlt_component_datatypes
740    */
741   const AliHLTUInt32_t kAliHLTVoidRunType = ~(AliHLTUInt32_t)0;
742
743   /** invalid run descriptor
744    * @ingroup alihlt_component_datatypes
745    */
746   const AliHLTRunDesc kAliHLTVoidRunDesc={sizeof(AliHLTRunDesc), kAliHLTVoidRunNo, kAliHLTVoidRunType};
747
748   /** invalid shared memory type */
749   const AliHLTUInt32_t gkAliHLTComponentInvalidShmType = 0;
750
751   /** invalid shared memory id */
752   const AliHLTUInt64_t gkAliHLTComponentInvalidShmID = ~(AliHLTUInt64_t)0;
753
754   /** invalid data type 
755    * @ingroup alihlt_component_datatypes
756    */
757   const AliHLTComponentDataType kAliHLTVoidDataType = {
758     sizeof(AliHLTComponentDataType),
759     kAliHLTVoidDataTypeID,
760     kAliHLTDataOriginVoid
761   };
762
763   /** all data types, means any + void data type
764    * @ingroup alihlt_component_datatypes
765    */
766   const AliHLTComponentDataType kAliHLTAllDataTypes = {
767     sizeof(AliHLTComponentDataType),
768     kAliHLTAllDataTypesID,
769     kAliHLTDataOriginAny
770   };
771
772   // there is currently a problem with rootcint if the predefined ids
773   // (commented below) are used. rootcint does not find the id if they
774   // are char arrays defined with {} and individual chars. If strings
775   // are used it works fine
776   /** any data type 
777    * @ingroup alihlt_component_datatypes
778    */
779   const AliHLTComponentDataType kAliHLTAnyDataType = {
780     sizeof(AliHLTComponentDataType),
781     kAliHLTAnyDataTypeID,
782     kAliHLTDataOriginAny
783   };
784
785   /** multiple output data types 
786    * @ingroup alihlt_component_datatypes
787    */
788   extern const AliHLTComponentDataType kAliHLTMultipleDataType;
789
790   /** data to file exchange subscriber 
791    * @ingroup alihlt_component_datatypes
792    */
793   extern const AliHLTComponentDataType kAliHLTDataTypeFXSCalib;
794
795   /** DDL list data type 
796    * @ingroup alihlt_component_datatypes
797    */
798   extern const AliHLTComponentDataType kAliHLTDataTypeDDL;
799
800   /** CLUSTERS data
801    * Common data type for the output of cluster finders, the exact
802    * format depends on the origin (detector)
803    * @ingroup alihlt_component_datatypes
804    */
805   extern const AliHLTComponentDataType kAliHLTDataTypeClusters;
806
807   /** SOR data type 
808    * @ingroup alihlt_component_datatypes
809    */
810   extern const AliHLTComponentDataType kAliHLTDataTypeSOR;
811
812   /** EOR data type 
813    * @ingroup alihlt_component_datatypes
814    */
815   extern const AliHLTComponentDataType kAliHLTDataTypeEOR;
816
817   /** Run type data block 
818    * @ingroup alihlt_component_datatypes
819    */
820   extern const AliHLTComponentDataType kAliHLTDataTypeRunType;
821
822   /** Event type specification 
823    * @ingroup alihlt_component_datatypes
824    */
825   extern const AliHLTComponentDataType kAliHLTDataTypeEvent;
826
827   /** ECS parameter event 
828    * - sent during the SOR event by the framework
829    * - contains the full ECS parameter string
830    * @ingroup alihlt_component_datatypes
831    */
832   extern const AliHLTComponentDataType kAliHLTDataTypeECSParam; // {ECSPARAM:PRIV}
833
834   /** Configuration event data type 
835    * @ingroup alihlt_component_datatypes
836    */
837   extern const AliHLTComponentDataType kAliHLTDataTypeComConf;
838
839   /** DCS value update event 
840    * @ingroup alihlt_component_datatypes
841    */
842   extern const AliHLTComponentDataType kAliHLTDataTypeUpdtDCS;
843
844   /** RAW DDL data specification, origin is 'any', data publisher origin correctly 
845    * @ingroup alihlt_component_datatypes
846    */
847   extern const AliHLTComponentDataType kAliHLTDataTypeDDLRaw;
848
849   /** AliMCEvent object data specification, origin is 'OFFL' 
850    * @ingroup alihlt_component_datatypes
851    */
852   extern const AliHLTComponentDataType kAliHLTDataTypeMCObject;
853
854   /** ESD object data specification, origin is 'any' 
855    * @ingroup alihlt_component_datatypes
856    */
857   extern const AliHLTComponentDataType kAliHLTDataTypeESDObject;
858
859   /** ESD Tree data specification, origin is 'any' 
860    * @ingroup alihlt_component_datatypes
861    */
862   extern const AliHLTComponentDataType kAliHLTDataTypeESDTree;
863
864   /** AliRoot TreeD data specification, origin is 'any' 
865    * @ingroup alihlt_component_datatypes
866    */
867   extern const AliHLTComponentDataType kAliHLTDataTypeAliTreeD;
868
869   /** AliRoot TreeR data specification, origin is 'any' 
870    * @ingroup alihlt_component_datatypes
871    */
872   extern const AliHLTComponentDataType kAliHLTDataTypeAliTreeR;
873
874   /** 16 bit Hardware address selection data specification, origin is 'any' 
875    * @ingroup alihlt_component_datatypes
876    */
877   extern const AliHLTComponentDataType kAliHLTDataTypeHwAddr16;
878
879   /** Event statistics 
880    * @ingroup alihlt_component_datatypes
881    */
882   extern const AliHLTComponentDataType kAliHLTDataTypeEventStatistics;
883
884   /** Event summary 
885    * @ingroup alihlt_component_datatypes
886    */
887   extern const AliHLTComponentDataType kAliHLTDataTypeEventSummary;
888
889   /** Event statistics 
890    * @ingroup alihlt_component_datatypes
891    */
892   extern const AliHLTComponentDataType kAliHLTDataTypeRunStatistics;
893
894   /** Event summary 
895    * @ingroup alihlt_component_datatypes
896    */
897   extern const AliHLTComponentDataType kAliHLTDataTypeRunSummary;
898
899   /** Component block statistics
900    * @ingroup alihlt_component_datatypes
901    */
902   extern const AliHLTComponentDataType kAliHLTDataTypeComponentStatistics;
903
904   /** Component table
905    * To be sent on SOR event, each component adds it's chain id string
906    * and a generated 32bit identifier to the table
907    * @ingroup alihlt_component_datatypes
908    */
909   extern const AliHLTComponentDataType kAliHLTDataTypeComponentTable;
910
911   //////////////////////////////////////////////////////////////////////////
912   //
913   // Data Types for Monitoring objects
914   //
915   //////////////////////////////////////////////////////////////////////////
916
917   /** general ROOT TObject 
918    * @ingroup alihlt_component_datatypes
919    */
920   extern const AliHLTComponentDataType kAliHLTDataTypeTObject;            // {ROOTTOBJ,"***"}
921                                                                                         
922   /** ROOT TObjArray 
923    * @ingroup alihlt_component_datatypes
924    */                                                                   
925   extern const AliHLTComponentDataType kAliHLTDataTypeTObjArray;          // {ROOTOBAR,"***"}
926                                                                                         
927   /** ROOT TTree 
928    * @ingroup alihlt_component_datatypes
929    */                                                                   
930   extern const AliHLTComponentDataType kAliHLTDataTypeTTree;              // {ROOTTREE,"***"}
931                                                                                         
932   /** ROOT TH1 (can be used for all histograms, they derive from TH1) 
933    * @ingroup alihlt_component_datatypes
934    */           
935   extern const AliHLTComponentDataType kAliHLTDataTypeHistogram;          // {ROOTHIST,"***"}
936                                                                                         
937   /** ROOT TNtuple 
938    * @ingroup alihlt_component_datatypes
939    */                                                                   
940   extern const AliHLTComponentDataType kAliHLTDataTypeTNtuple;            // {ROOTTUPL,"***"}
941
942   /** General track array for the barrel tracks based on AliExternalTrackParam
943    * Data format defined by AliHLTTracksData
944    *
945    * We follow the naming scheme of AliESDEvent where 'Tracks' denote the
946    * barrel tracks and detector tracks get names 'DETTracks'
947    * @ingroup alihlt_component_datatypes
948    */   
949   extern const AliHLTComponentDataType kAliHLTDataTypeTrack;              // {HLTTRACK,"***"}
950
951   /** TClonesArray of AliExternalTrackParam
952    * @ingroup alihlt_component_datatypes
953    */   
954   extern const AliHLTComponentDataType kAliHLTDataTypeExternalTrackParam; // {TCAEXTTR,"***"}
955
956   /** Container containing jets (AliHLTJETJets)
957    * Containing TClonesArray of AliAODJets 
958    * @ingroup alihlt_component_datatypes
959    */   
960   extern const AliHLTComponentDataType kAliHLTDataTypeJet;                // {HLTJETV0,"***"}
961   
962   /** Container of ITS tracks
963    * @ingroup alihlt_component_datatypes
964    */   
965   extern const AliHLTComponentDataType fgkITSTracksDataType;
966
967   //////////////////////////////////////////////////////////////////////////
968   //
969   // FXS subscriber meta information
970   //
971   //////////////////////////////////////////////////////////////////////////
972
973   const int gkAliHLTFXSHeaderfOriginSize = 4;
974   const int gkAliHLTFXSHeaderfFileIDSize = 128;
975   const int gkAliHLTFXSHeaderfDDLNumberSize = 64;
976
977   /** Header in front of the data payload, in order to sent data to the FXS. */
978   struct AliHLTFXSHeader
979   {
980     AliHLTUInt32_t fHeaderVersion;   /// HLT software version number.
981     AliHLTUInt32_t fRunNumber;       /// The current run number.
982     char fOrigin[gkAliHLTFXSHeaderfOriginSize];   /// The detector from which the FXS data is received.
983     char fFileID[gkAliHLTFXSHeaderfFileIDSize];   /// File identifier for the stored data.
984     char fDDLNumber[gkAliHLTFXSHeaderfDDLNumberSize];  /// The DDL bits.
985   };  
986
987   //////////////////////////////////////////////////////////////////////////
988   //
989   // Component running environment
990   //
991   //////////////////////////////////////////////////////////////////////////
992
993   /** logging function */
994   typedef int (*AliHLTfctLogging)( void* param, 
995                                    AliHLTComponentLogSeverity severity,
996                                    const char* origin,
997                                    const char* keyword,
998                                    const char* message);
999
1000   /**
1001    * @struct AliHLTAnalysisEnvironment
1002    * Running environment for analysis components.
1003    * The struct describes function callbacks for actions to be
1004    * carried out by the calling framework, like memory allocation,
1005    * property callbecks, logging, etc.
1006    *
1007    * @ingroup alihlt_wrapper_interface
1008    */
1009   struct AliHLTAnalysisEnvironment
1010   {
1011     /** size of the structure */
1012     AliHLTUInt32_t fStructSize;
1013
1014     /** the component parameter given by the framework on creation */
1015     void* fParam;
1016
1017     /** allocated memory */
1018     void* (*fAllocMemoryFunc)( void* param, unsigned long size );
1019
1020     /** allocate an EventDoneData structure. */
1021     int (*fGetEventDoneDataFunc)( void* param, AliHLTEventID_t eventID, unsigned long size, AliHLTComponentEventDoneData** edd );
1022
1023     /** logging callback */
1024     AliHLTfctLogging fLoggingFunc;
1025   };
1026 #if 0
1027   // I just keep this as a note pad. Has to be added to the end of the structure
1028   // future addition already foreseen/envisioned
1029   // IMPORTANT: don not just remove the defines as this breaks the binary
1030   // compatibility
1031   int (*fAllocShmMemoryFunc)( void* param, unsigned long size, AliHLTComponentBlockData* blockLocation );
1032 #endif
1033
1034   /**
1035    * @struct AliHLTComponentEnvironment
1036    * This was the original definition of the running environment.
1037    * Due to a bug in the AliRootWrapperSubscriber/SimpleComponentWrapper,
1038    * this structure can not be used any longer but is kept for backward
1039    * compatibility. 
1040    * @note The external interface provided by the libHLTbase is now kept
1041    * frozen but should not be used any more. Use the interface provided
1042    * by the libHLTinterface library.
1043    *
1044    * @ingroup alihlt_wrapper_interface_deprecated
1045    */
1046   struct AliHLTComponentEnvironment
1047   {
1048     AliHLTUInt32_t fStructSize;
1049     void* fParam;
1050     void* (*fAllocMemoryFunc)( void* param, unsigned long size );
1051     int (*fGetEventDoneDataFunc)( void* param, AliHLTEventID_t eventID, unsigned long size, AliHLTComponentEventDoneData** edd );
1052     AliHLTfctLogging fLoggingFunc;
1053   };
1054
1055   //////////////////////////////////////////////////////////////////////////
1056   //
1057   // The external interface definition
1058   //
1059   //////////////////////////////////////////////////////////////////////////
1060
1061   /**
1062    * The component handle.
1063    * Used as indification in the outside world.
1064    * @ingroup alihlt_wrapper_interface
1065    */
1066   typedef void* AliHLTComponentHandle;
1067
1068   /** @ingroup alihlt_wrapper_interface */
1069   const AliHLTComponentHandle kEmptyHLTComponentHandle = 0;
1070
1071   /**
1072    * Get a system call of the interface.
1073    * @param function signature
1074    * @return pointer to system call
1075    * @ingroup alihlt_wrapper_interface
1076    */
1077   typedef void* (*AliHLTAnalysisFctGetInterfaceCall)(const char*);
1078
1079 # define ALIHLTANALYSIS_INTERFACE_LIBRARY  "libHLTinterface.so"
1080 # define ALIHLTANALYSIS_FCT_GETINTERFACECALL  "AliHLTAnalysisGetInterfaceCall"
1081
1082   /** @ingroup alihlt_wrapper_interface */
1083   typedef int (*AliHLTExtFctInitSystem)( unsigned long version, AliHLTAnalysisEnvironment* externalEnv, unsigned long runNo, const char* runType );
1084
1085   /** @ingroup alihlt_wrapper_interface */
1086   typedef int (*AliHLTExtFctDeinitSystem)();
1087
1088   /** @ingroup alihlt_wrapper_interface */
1089   typedef int (*AliHLTExtFctLoadLibrary)( const char* );
1090
1091   /** @ingroup alihlt_wrapper_interface */
1092   typedef int (*AliHLTExtFctUnloadLibrary)( const char* );
1093
1094   /** @ingroup alihlt_wrapper_interface */
1095   typedef int (*AliHLTExtFctCreateComponent)( const char*, void*, int, const char**, AliHLTComponentHandle*, const char* description );
1096
1097   /** @ingroup alihlt_wrapper_interface */
1098   typedef int (*AliHLTExtFctDestroyComponent)( AliHLTComponentHandle );
1099
1100   /** @ingroup alihlt_wrapper_interface */
1101   typedef int (*AliHLTExtFctProcessEvent)( AliHLTComponentHandle, const AliHLTComponentEventData*, const AliHLTComponentBlockData*, 
1102                                            AliHLTComponentTriggerData*, AliHLTUInt8_t*,
1103                                            AliHLTUInt32_t*, AliHLTUInt32_t*, 
1104                                            AliHLTComponentBlockData**,
1105                                            AliHLTComponentEventDoneData** );
1106
1107   /** @ingroup alihlt_wrapper_interface */
1108   typedef int (*AliHLTExtFctGetOutputDataType)( AliHLTComponentHandle, AliHLTComponentDataType* );
1109
1110   /** @ingroup alihlt_wrapper_interface */
1111   typedef int (*AliHLTExtFctGetOutputSize)( AliHLTComponentHandle, unsigned long*, double* );
1112
1113 }
1114
1115 //////////////////////////////////////////////////////////////////////////
1116 //
1117 // Data type helper functions
1118 //
1119 //////////////////////////////////////////////////////////////////////////
1120
1121 /** exact comparison of HLT component data types
1122  * @ingroup alihlt_component_datatypes
1123  */
1124 inline bool MatchExactly( const AliHLTComponentDataType& dt1, const AliHLTComponentDataType& dt2 )
1125 {
1126   for ( int i = 0; i < kAliHLTComponentDataTypefIDsize; i++ )
1127     if ( dt1.fID[i] != dt2.fID[i] )
1128       return false;
1129   for ( int i = 0; i < kAliHLTComponentDataTypefOriginSize; i++ )
1130     if ( dt1.fOrigin[i] != dt2.fOrigin[i] )
1131       return false;
1132   return true;
1133 }
1134
1135 /** Comparison operator for HLT component data types.
1136  * The operator takes wildcards into account, i.e. the ::kAliHLTAnyDataType,
1137  * ::kAliHLTAnyDataTypeID and ::kAliHLTDataOriginAny definitions.
1138  * @ingroup alihlt_component_datatypes
1139  */
1140 inline bool operator==( const AliHLTComponentDataType& dt1, const AliHLTComponentDataType& dt2 )
1141 {
1142   if (MatchExactly(dt1, kAliHLTAllDataTypes)) return true;
1143   if (MatchExactly(dt2, kAliHLTAllDataTypes)) return true;
1144
1145   bool any1=true, any2=true, void1=true, void2=true, match=true;
1146   for ( int i = 0; i < kAliHLTComponentDataTypefOriginSize; i++ ) {
1147     any1&=(dt1.fOrigin[i]==kAliHLTDataOriginAny[i]);
1148     any2&=(dt2.fOrigin[i]==kAliHLTDataOriginAny[i]);
1149     void1&=(dt1.fOrigin[i]==kAliHLTDataOriginVoid[i]);
1150     void2&=(dt2.fOrigin[i]==kAliHLTDataOriginVoid[i]);
1151     match&=dt1.fOrigin[i]==dt2.fOrigin[i];
1152     if (!(match || (any2 && !void1) || (any1 && !void2)))
1153       return false;
1154   }
1155
1156   any1=true, any2=true, match=true;
1157   for ( int i = 0; i < kAliHLTComponentDataTypefIDsize; i++ ) {
1158     any1&=(dt1.fID[i]==kAliHLTAnyDataTypeID[i]);
1159     any2&=(dt2.fID[i]==kAliHLTAnyDataTypeID[i]);
1160     void1&=(dt1.fID[i]==kAliHLTVoidDataTypeID[i]);
1161     void2&=(dt2.fID[i]==kAliHLTVoidDataTypeID[i]);
1162     match&=dt1.fID[i]==dt2.fID[i];
1163     if (!(match || (any2 && !void1) || (any1 && !void2)))
1164       return false;
1165   }
1166   return true;
1167 }
1168
1169 /** Comparison operator for HLT component data types
1170  * Invers of operator==
1171  * @ingroup alihlt_component_datatypes
1172  */
1173 inline bool operator!=( const AliHLTComponentDataType& dt1, const AliHLTComponentDataType& dt2 )
1174 {
1175   return !(dt1==dt2);
1176 }
1177
1178 /** merge operator for HLT component data types and origins
1179  * @ingroup alihlt_component_datatypes
1180  */
1181 inline AliHLTComponentDataType operator|(const AliHLTComponentDataType srcdt, const char origin[kAliHLTComponentDataTypefOriginSize])
1182 {
1183   AliHLTComponentDataType dt=srcdt;
1184   for ( int i = 0; i < kAliHLTComponentDataTypefOriginSize; i++ )
1185     dt.fOrigin[i]=origin[i];
1186   return dt;
1187 }
1188
1189 /**
1190  * Helper function to initialize a data type from an id char array and origin string.
1191  * @return data type structure initialized with the specified id and origin
1192  * @ingroup alihlt_component_datatypes
1193  */
1194 inline AliHLTComponentDataType AliHLTComponentDataTypeInitializer(const char id[kAliHLTComponentDataTypefIDsize], const char* origin)
1195 {
1196   AliHLTComponentDataType dt=kAliHLTVoidDataType;
1197   int i=0;
1198   for (i = 0; i < kAliHLTComponentDataTypefIDsize; i++)
1199     dt.fID[i]=id[i];
1200   for (i = 0; i < kAliHLTComponentDataTypefOriginSize && origin[i]!=0; i++ )
1201     dt.fOrigin[i]=origin[i];
1202   return dt;
1203 }
1204
1205 /**
1206  * Helper function to initialize a data type from a default data type and
1207  * an origin string. Basically it merges the specified origin into the data
1208  * type.
1209  * @return data type structure initialized with the id from specified data type
1210  *         and origin
1211  * @ingroup alihlt_component_datatypes
1212  */
1213 inline AliHLTComponentDataType AliHLTComponentDataTypeInitializer(const AliHLTComponentDataType src, const char* origin)
1214 {
1215   return AliHLTComponentDataTypeInitializer(src.fID, origin);
1216 }
1217
1218 #endif