3 #ifndef ALIHLTDUMPTASK_H
4 #define ALIHLTDUMPTASK_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 *
9 /** @file AliHLTDumpTask.h
10 @author Matthias Richter
12 @brief Base class for data sinks with direct buffer access.
15 #include "AliHLTOUT.h"
16 #include "AliHLTTask.h"
19 * @class AliHLTDumpTask
20 * A base class for data sinks without a processing component. Tasks of this
21 * type can be added at the end of the processing chain and allow direct
22 * access to the data blocks produced by the last components of the chain.
24 * The constructor takes the chains as a blank separated list of chain ids.
26 * @ingroup alihlt_system
28 class AliHLTDumpTask : public AliHLTTask {
31 AliHLTDumpTask(const char* chains=NULL);
32 /** standard destructor */
33 virtual ~AliHLTDumpTask();
36 * Set the parent reconstruction chains this task is going to subscribe to.
37 * @param chains blank separated list of chain ids
39 int SetChains(const char* chains);
42 * Get string of the source chains.
44 const char* GetSourceChains() const;
47 * Get the list of data blocks.
48 * Subscribe to the publishers if not yet done and return pointer
51 const AliHLTComponentBlockDataList& GetDataBlocks();
54 * Explicitly release data blocks.
56 int ReleaseDataBlocks();
61 /** copy constructor prohibited */
62 AliHLTDumpTask(const AliHLTDumpTask&);
63 /** assignment operator prohibited */
64 AliHLTDumpTask& operator=(const AliHLTDumpTask&);
67 * Custom initialization for child tasks.
68 * Create and init the dummy task.
70 int CustomInit(AliHLTComponentHandler* pCH);
73 * Custom clean up for child tasks.
77 /** a dummy task to pretend existence of a consumer */
78 AliHLTTask* fpDummyTask; //!transient
80 /** the configuration for the dummy task */
81 AliHLTConfiguration* fpDummyConfiguration; //!transient
83 /** list of block descriptors of the output */
84 AliHLTComponentBlockDataList fBlocks;
86 ClassDef(AliHLTDumpTask, 0)