Added methods for finding a given module in the DDL map (F. Prino)
[u/mrichter/AliRoot.git] / STEER / AliTriggerClass.h
CommitLineData
51f6d619 1#ifndef ALITRIGGERCLASS_H
2#define ALITRIGGERCLASS_H
3
4/* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
5 * See cxx source for full Copyright notice */
6
7///////////////////////////////////////////////////////////////////////////////
8// //
9// This class represents the CTP class objects //
10// //
11// The Class consists of Name, descriptor, mask, protection, index in the //
12// trigger mask //
13// //
14// //
15///////////////////////////////////////////////////////////////////////////////
16
17#include <TNamed.h>
18
19class AliTriggerConfiguration;
20class AliTriggerDescriptor;
21class AliTriggerCluster;
22class AliTriggerPFProtection;
23class AliTriggerBCMask;
24
25class AliTriggerClass : public TNamed {
26
27public:
28 AliTriggerClass();
29 AliTriggerClass( TString & name, UChar_t index,
30 AliTriggerDescriptor *desc, AliTriggerCluster *clus,
31 AliTriggerPFProtection *pfp, AliTriggerBCMask *mask,
32 UInt_t prescaler, Bool_t allrare);
33 AliTriggerClass( AliTriggerConfiguration *config,
34 TString & name, UChar_t index,
35 TString &desc, TString &clus,
36 TString &pfp, TString &mask,
37 UInt_t prescaler, Bool_t allrare);
38
39 AliTriggerClass( const AliTriggerClass& trclass );
40 virtual ~AliTriggerClass();
41 AliTriggerClass& operator=(const AliTriggerClass& trclass);
42
43 void Reset() { fStatus = kFALSE; }
44
45 ULong64_t GetValue() const { return (fStatus) ? fClassMask : 0; }
46 Bool_t GetStatus() const { return fStatus; }
47 ULong64_t GetMask() const { return fClassMask; }
48 AliTriggerDescriptor* GetDescriptor() const { return fDescriptor; }
49 AliTriggerCluster* GetCluster() const { return fCluster; }
50
51 void Trigger( const TObjArray& inputs , const TObjArray& functions);
52 void Print( const Option_t* ) const;
53
54 Bool_t CheckClass(AliTriggerConfiguration *config) const;
55 Bool_t IsActive( const TObjArray& inputs, const TObjArray& functions) const;
56private:
57 ULong64_t fClassMask; // position of the class in the trigger pattern
58 AliTriggerDescriptor* fDescriptor; // pointer to the descriptor
59 AliTriggerCluster* fCluster; // pointer to the cluster
60 AliTriggerPFProtection* fPFProtection; // pointer to the past-future protection
61 AliTriggerBCMask* fMask; // pointer to bunch-crossing mask
62 UInt_t fPrescaler; // Downscaling factor
63 Bool_t fAllRare; // All or Rare trigger
64 Bool_t fStatus; //! true = Condition has been satisfied after Trigger
65
66 ClassDef( AliTriggerClass, 1 ) // Define a trigger class object
67};
68
69#endif