]>
Commit | Line | Data |
---|---|---|
1b9a175e | 1 | #ifndef ALIHLTGLOBALTRIGGERDECISION_H |
2 | #define ALIHLTGLOBALTRIGGERDECISION_H | |
3 | /* This file is property of and copyright by the ALICE HLT Project * | |
4 | * ALICE Experiment at CERN, All rights reserved. * | |
5 | * See cxx source for full Copyright notice */ | |
6 | ||
7 | /// @file AliHLTGlobalTriggerDecision.h | |
8 | /// @author Artur Szostak <artursz@iafrica.com> | |
9 | /// @date 26 Nov 2008 | |
10 | /// @brief Declaration of the AliHLTGlobalTriggerDecision class storing the global HLT decision. | |
11 | ||
12 | #include "AliHLTTriggerDecision.h" | |
e2bb8ddd | 13 | #include "TArrayL64.h" |
1b9a175e | 14 | |
15 | class AliHLTGlobalTriggerDecision : public AliHLTTriggerDecision | |
16 | { | |
17 | public: | |
18 | ||
19 | /** | |
20 | * Default constructor. | |
21 | */ | |
22 | AliHLTGlobalTriggerDecision(); | |
23 | ||
24 | /** | |
25 | * Constructor specifying multiple information fields. | |
26 | * \param result The result of the global trigger decision. | |
27 | * \param readoutList The DDL readout list for the global trigger decision. | |
28 | * \param triggerDomain The trigger domain for the global trigger decision. | |
29 | * \param description The description of (reason for) the global trigger decision. | |
30 | */ | |
31 | AliHLTGlobalTriggerDecision( | |
32 | bool result, const AliHLTReadoutList& readoutList, | |
33 | const AliHLTTriggerDomain& triggerDomain, const char* description = "" | |
34 | ); | |
35 | ||
36 | /** | |
37 | * Default destructor. | |
38 | */ | |
39 | virtual ~AliHLTGlobalTriggerDecision(); | |
40 | ||
41 | /** | |
42 | * Inherited from TObject, this prints the contents of the trigger decision. | |
43 | * \param option Can be "short" which will print the short format. | |
44 | */ | |
45 | virtual void Print(Option_t* option = "") const; | |
46 | ||
47 | /** | |
48 | * Returns the number of trigger inputs that contributed to this global trigger decision. | |
49 | */ | |
50 | Int_t NumberOfTriggerInputs() const { return fContributingTriggers.GetEntriesFast(); } | |
51 | ||
52 | /** | |
53 | * Returns the i'th trigger input object in fContributingTriggers. | |
54 | */ | |
55 | const AliHLTTriggerDecision* TriggerInput(Int_t i) const | |
56 | { | |
57 | return static_cast<const AliHLTTriggerDecision*>( fContributingTriggers[i] ); | |
58 | } | |
59 | ||
60 | /** | |
61 | * Returns the list of trigger inputs used when making the global HLT trigger decision. | |
62 | */ | |
63 | const TClonesArray& TriggerInputs() const { return fContributingTriggers; } | |
64 | ||
65 | /** | |
66 | * Adds a trigger input to the list of triggers that were considered when making | |
67 | * this global trigger decision. | |
68 | * \param decision The trigger decision object to add. | |
69 | */ | |
70 | void AddTriggerInput(const AliHLTTriggerDecision& decision) | |
71 | { | |
72 | new (fContributingTriggers[fContributingTriggers.GetEntriesFast()]) AliHLTTriggerDecision(decision); | |
73 | } | |
74 | ||
75 | /** | |
76 | * Returns the event trigger counters associated with the global trigger classes. | |
77 | */ | |
e2bb8ddd | 78 | const TArrayL64& Counters() const { return fCounters; } |
1b9a175e | 79 | |
80 | private: | |
81 | ||
82 | TClonesArray fContributingTriggers; /// The list of contributing trigger decisions from all AliHLTTrigger components that were considered. | |
e2bb8ddd | 83 | TArrayL64 fCounters; /// Event trigger counters. One counter for each trigger class in the global trigger. |
1b9a175e | 84 | |
85 | ClassDef(AliHLTGlobalTriggerDecision, 1) // Contains the HLT global trigger decision and information contributing to the decision. | |
86 | }; | |
87 | ||
88 | #endif // ALIHLTGLOBALTRIGGERDECISION_H | |
89 |