1 | #ifndef MARS_MFTriggerPattern
|
---|
2 | #define MARS_MFTriggerPattern
|
---|
3 |
|
---|
4 | #ifndef MARS_MFilter
|
---|
5 | #include "MFilter.h"
|
---|
6 | #endif
|
---|
7 |
|
---|
8 | class MTriggerPattern;
|
---|
9 |
|
---|
10 | class MFTriggerPattern : public MFilter
|
---|
11 | {
|
---|
12 | public:
|
---|
13 | enum Prescale_t {
|
---|
14 | kUnPrescaled,
|
---|
15 | kPrescaled
|
---|
16 | };
|
---|
17 |
|
---|
18 | private:
|
---|
19 | MTriggerPattern *fPattern; //!
|
---|
20 |
|
---|
21 | Byte_t fMaskRequiredPrescaled; // Mask for filtering Trigger Pattern allowed
|
---|
22 | Byte_t fMaskRequiredUnprescaled; // Mask for filtering Trigger Pattern allowed
|
---|
23 | Byte_t fMaskDeniedPrescaled; // Mask for filtering Trigger Pattern denied
|
---|
24 | Byte_t fMaskDeniedUnprescaled; // Mask for filtering Trigger Pattern denied
|
---|
25 |
|
---|
26 | Bool_t fDefault; // Default which is used if trigger pattern has default value (p==0&&u==0)
|
---|
27 | Bool_t fResult; //!
|
---|
28 |
|
---|
29 | Int_t PreProcess(MParList *pList);
|
---|
30 | Int_t Process();
|
---|
31 |
|
---|
32 | Bool_t IsExpressionTrue() const;
|
---|
33 |
|
---|
34 | public:
|
---|
35 | MFTriggerPattern(const char *name=NULL, const char *title=NULL);
|
---|
36 | MFTriggerPattern(MFTriggerPattern &trigpatt);
|
---|
37 |
|
---|
38 | void RequireTriggerLvl1(Prescale_t prescaled=kUnPrescaled);
|
---|
39 | void RequireTriggerLvl2(Prescale_t prescaled=kUnPrescaled);
|
---|
40 | void RequireCalibration(Prescale_t prescaled=kUnPrescaled);
|
---|
41 | void RequirePedestal(Prescale_t prescaled=kUnPrescaled);
|
---|
42 | void RequirePinDiode(Prescale_t prescaled=kUnPrescaled);
|
---|
43 | void RequireSumTrigger(Prescale_t prescaled=kUnPrescaled);
|
---|
44 |
|
---|
45 | void DenyTriggerLvl1(Prescale_t prescaled=kUnPrescaled);
|
---|
46 | void DenyTriggerLvl2(Prescale_t prescaled=kUnPrescaled);
|
---|
47 | void DenyCalibration(Prescale_t prescaled=kUnPrescaled);
|
---|
48 | void DenyPedestal(Prescale_t prescaled=kUnPrescaled);
|
---|
49 | void DenyPinDiode(Prescale_t prescaled=kUnPrescaled);
|
---|
50 | void DenySumTrigger(Prescale_t prescaled=kUnPrescaled);
|
---|
51 |
|
---|
52 | void Require(TString patt, Prescale_t prescaled=kUnPrescaled);
|
---|
53 | void Deny(TString patt, Prescale_t prescaled=kUnPrescaled);
|
---|
54 |
|
---|
55 | void SetDefault(Bool_t b) { fDefault=b; }
|
---|
56 |
|
---|
57 | // Low level settings. USE THESE ONLY IF YOU ARE AN EXPERT!
|
---|
58 | void SetMaskRequired(const Byte_t mask, Prescale_t prescaled=kUnPrescaled);
|
---|
59 | void SetMaskDenied(const Byte_t mask, Prescale_t prescaled=kUnPrescaled);
|
---|
60 |
|
---|
61 | ClassDef(MFTriggerPattern, 1) // A Filter for the Trigger Pattern
|
---|
62 | };
|
---|
63 |
|
---|
64 | #endif
|
---|