- support for event by event reconstruction added to AliHLTSystem
[u/mrichter/AliRoot.git] / HLT / SampleLib / AliHLTAgentSample.h
CommitLineData
242bb794 1// @(#) $Id$
2
3#ifndef ALIHLTAGENTSAMPLE_H
4#define ALIHLTAGENTSAMPLE_H
5/* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
6 * See cxx source for full Copyright notice */
7
8/** @file AliHLTAgentSample.h
9 @author Matthias Richter
10 @date
11 @brief Agent of the libAliHLTSample library
12*/
13
14#include "AliHLTModuleAgent.h"
15
16/**
17 * @class AliHLTAgentSample
90ebac25 18 * This is the agent for the AliHLTSample library.<br>
19 * The AliHLTSample library illustrates usage of the HLT framework. The
20 * agent provides information on the features of the sample components
21 * and the configuration which should be run during AliRoot reconstruction.
242bb794 22 *
90ebac25 23 * The sample agent implements all interface function provided by @ref
24 * AliHLTModuleAgent :
25 * - @ref CreateConfigurations <br>
26 * The method gets an instance of the AliHLTConfigurationHanler to add
27 * configurations, e.g.
28 * <pre>
29 * handler->CreateConfiguration("my-puplisher" , "FilePublisher", NULL , "data.bin");
30 * ...
31 * handler->CreateConfiguration("my-analysis-chain" , "FileWriter", "my-processor" , "my arguments");
32 * </pre>
dee38f1b 33 * - @ref GetReconstructionChains <br>
90ebac25 34 * returns a string of blank separated configurations to be run during
35 * local event reconstruction.
36 * <pre>
37 * return "my-data-sink my-analysis-chain";
38 * </pre>
39 * - @ref GetRequiredComponentLibraries <br>
40 * returns a string of blank separated libraries which have to be loaded
dee38f1b 41 * in addition in order to load all required components. <br>
42 * @note Not the right place for library dependencies.
90ebac25 43 * <pre>
44 * return "libAliHLTUtil.so";
45 * </pre>
46 * - not implemented are the in iterface methods
47 * - @ref AliHLTModuleAgent::GetEventRecConfigurations
48 * - @ref AliHLTModuleAgent::RegisterComponents
49 *
50 * In order to hook the sample library up to the HLT system on global object
51 * @ref gAliHLTAgentSample of the agent is defined in the source code.
52 *
242bb794 53 * @ingroup alihlt_system
54 */
55class AliHLTAgentSample : public AliHLTModuleAgent {
56 public:
57 /**
58 * standard constructor. The agent is automatically registered in the
59 * global agent manager
60 */
61 AliHLTAgentSample();
62 /** destructor */
63 virtual ~AliHLTAgentSample();
64
65 /**
90ebac25 66 * Register all configurations belonging to the sample library with the
242bb794 67 * AliHLTConfigurationHandler. The agent can adapt the configurations
68 * to be registered to the current AliRoot setup by checking the
69 * runloader.
dee38f1b 70 * @param handler [in] the configuration handler
71 * @param rawReader [in] AliRoot RawReader instance
72 * @param runloader [in] AliRoot runloader
242bb794 73 * @return neg. error code if failed
74 */
75 int CreateConfigurations(AliHLTConfigurationHandler* handler,
dee38f1b 76 AliRawReader* rawReader=NULL,
242bb794 77 AliRunLoader* runloader=NULL) const;
78
79 /**
90ebac25 80 * Get the top configurations for local event reconstruction.
242bb794 81 * A top configuration describes a processing chain. It can simply be
82 * described by the last configuration(s) in the chain.
83 * The agent can adapt the configurations to be registered to the current
84 * AliRoot setup by checking the runloader.
dee38f1b 85 * @param rawReader [in] AliRoot RawReader instance
86 * @param runloader [in] AliRoot runloader
90ebac25 87 * @return string containing the top configurations separated by blanks
242bb794 88 */
dee38f1b 89 const char* GetReconstructionChains(AliRawReader* rawReader=NULL,
90 AliRunLoader* runloader=NULL) const;
242bb794 91
92 /**
93 * Component libraries which the configurations of this agent depend on.
94 * @return list of component libraries as a blank-separated string.
95 */
96 const char* GetRequiredComponentLibraries() const;
97
98 protected:
99
100 private:
90ebac25 101 /** file name of the generated test data*/
102 static const char* fgkAliHLTAgentSampleData; //!transient
103
104 /** file name of the output file */
105 static const char* fgkAliHLTAgentSampleOut; //!transient
106
107 /** ROOT specific member definition */
108 ClassDef(AliHLTAgentSample, 1);
242bb794 109};
110
111#endif