4 #ifndef ALIHLTTPCAGENT_H
5 #define ALIHLTTPCAGENT_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 AliHLTTPCAgent.h
11 // @author Matthias Richter
13 // @brief Agent of the libAliHLTTPC library
16 #include "AliHLTModuleAgent.h"
17 #include "AliHLTOUTHandlerEquId.h"
19 class AliHLTOUTHandlerChain;
22 * @class AliHLTTPCAgent
23 * This is the agent for the AliHLTTPC library.
25 * @ingroup alihlt_system
27 class AliHLTTPCAgent : public AliHLTModuleAgent {
30 * standard constructor. The agent is automatically registered in the
31 * global agent manager
35 virtual ~AliHLTTPCAgent();
38 * Register all configurations belonging to this module with the
39 * AliHLTConfigurationHandler. The agent can adapt the configurations
40 * to be registered to the current AliRoot setup by checking the
42 * @param handler the configuration handler
43 * @param rawReader AliRawReader instance
44 * @param runloader AliRoot runloader
45 * @return neg. error code if failed
47 int CreateConfigurations(AliHLTConfigurationHandler* handler,
48 AliRawReader* rawReader=NULL,
49 AliRunLoader* runloader=NULL) const;
52 * Get the top configurations belonging to this module.
53 * A top configuration describes a processing chain. It can simply be
54 * described by the last configuration(s) in the chain.
55 * The agent can adapt the configurations to be registered to the current
56 * AliRoot setup by checking the runloader.
57 * @param rawReader AliRawReader instance
58 * @param runloader AliRoot runloader
59 * @return number of configurations, neg. error code if failed
61 const char* GetReconstructionChains(AliRawReader* rawReader=NULL,
62 AliRunLoader* runloader=NULL) const;
65 * Component libraries which the configurations of this agent depend on.
66 * @return list of component libraries as a blank-separated string.
68 const char* GetRequiredComponentLibraries() const;
71 * Register components for the AliHLTTPC library.
72 * @param [in] pHandler instance of the component handler
74 int RegisterComponents(AliHLTComponentHandler* pHandler) const;
77 * Get handler decription for TPC data in the HLTOUT data stream.
78 * @param [in] dt data type of the block
79 * @param [in] spec specification of the block
80 * @param [out] desc handler description
81 * @return 1 if the agent can provide a handler, 0 if not
83 int GetHandlerDescription(AliHLTComponentDataType dt,
85 AliHLTOUTHandlerDesc& desc) const;
88 * Get specific handler for TPC data in the HLTOUT data stream.
89 * @param [in] dt data type of the block
90 * @param [in] spec specification of the block
91 * @return pointer to handler
93 AliHLTOUTHandler* GetOutputHandler(AliHLTComponentDataType dt,
97 * Delete an HLTOUT handler.
98 * @param pInstance pointer to handler
100 int DeleteOutputHandler(AliHLTOUTHandler* pInstance);
103 * The handler for TPC RAW data in the HLTOUT stream.
105 class AliHLTTPCRawDataHandler : public AliHLTOUTHandlerEquId {
108 AliHLTTPCRawDataHandler();
110 ~AliHLTTPCRawDataHandler();
113 * Process a data block.
114 * Decode specification and return equipment id of the data block.
115 * The data itsself i untouched.
116 * @return equipment id the block should be used for.
118 int ProcessData(AliHLTOUT* pData);
125 // indicate cluster id data blocks in the HLTOUT
126 kHaveCompressedClusterIdDataBlock = BIT(15)
132 /** copy constructor prohibited */
133 AliHLTTPCAgent(const AliHLTTPCAgent&);
134 /** assignment operator prohibited */
135 AliHLTTPCAgent& operator=(const AliHLTTPCAgent&);
137 /** handler for TPC raw data in the HLTOUT stream */
138 AliHLTTPCRawDataHandler* fRawDataHandler; //!transient
140 /** afterburner for {'TRAKSEGS':'TPC '} in the HLTOUT stream */
141 AliHLTOUTHandlerChain* fTracksegsDataHandler; //! transient
143 /// handler for {'CLUSTERS':'TPC '}
144 AliHLTOUTHandlerChain* fClustersDataHandler; //! transient
146 /// handler for data blocks related to data compression
147 AliHLTOUTHandlerChain* fCompressionMonitorHandler; //! transient
149 ClassDef(AliHLTTPCAgent, 0);