3 #ifndef ALIHLTPROCESSOR_H
4 #define ALIHLTPROCESSOR_H
5 /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
6 * See cxx source for full Copyright notice */
8 /** @file AliHLTProcessor.h
9 @author Matthias Richter, Timm Steinbeck
11 @brief Base class declaration for HLT analysis components. */
13 #include "AliHLTComponent.h"
16 * @class AliHLTProcessor
17 * Base class of HLT data analysis components.
18 * The class provides a common interface for the implementation of HLT data
19 * analysis components. The child class must implement the functions:
20 * - @ref DoInit (optional)
21 * - @ref DoDeinit (optional)
23 * - @ref GetComponentID
24 * - @ref GetInputDataTypes
25 * - @ref GetOutputDataType
26 * - @ref GetOutputDataSize
29 * @ingroup alihlt_component
31 class AliHLTProcessor : public AliHLTComponent {
33 /** standard constructor */
35 /** standard destructor */
36 virtual ~AliHLTProcessor();
39 int Init( AliHLTComponentEnvironment* environ, void* environ_param, int argc, const char** argv );
44 * Event processing function.
45 * The method is called by the framework to process one event. After
46 * preparation of data structures. The call is redirected to DoEvent.
47 * @return neg. error code if failed
49 int ProcessEvent( const AliHLTComponentEventData& evtData,
50 const AliHLTComponentBlockData* blocks,
51 AliHLTComponentTriggerData& trigData,
52 AliHLTUInt8_t* outputPtr,
54 AliHLTUInt32_t& outputBlockCnt,
55 AliHLTComponentBlockData*& outputBlocks,
56 AliHLTComponentEventDoneData*& edd );
58 // Information member functions for registration.
61 * Return @ref AliHLTComponent::kProcessor type as component type.
62 * @return component type id
64 TComponentType GetComponentType() { return AliHLTComponent::kProcessor;}
68 * Data processing method for the component.
69 * @param evtData event data structure
70 * @param blocks input data block descriptors
71 * @param trigData trigger data structure
72 * @param outputPtr pointer to target buffer
73 * @param size <i>input</i>: size of target buffer
74 * <i>output</i>:size of produced data
75 * @param outputBlocks list to receive output block descriptors
77 virtual int DoEvent( const AliHLTComponentEventData& evtData,
78 const AliHLTComponentBlockData* blocks,
79 AliHLTComponentTriggerData& trigData,
80 AliHLTUInt8_t* outputPtr,
82 vector<AliHLTComponentBlockData>& outputBlocks ) = 0;
84 ClassDef(AliHLTProcessor, 0)