00001 #pragma once
00002 #ifndef ANALYSISTRIGGEREVENT_TRIGGERDECISION_H
00003 #define ANALYSISTRIGGEREVENT_TRIGGERDECISION_H
00004
00010 #include <map>
00011 #include <string>
00012 #include <vector>
00013
00014 #include "CLIDSvc/CLASS_DEF.h"
00015
00016
00017 #include "TrigSteeringEvent/MessageSvcProvider.h"
00018
00023 class TriggerDecision
00024 {
00025 public:
00026
00027 enum TrigLevel {L1=1,L2,EF};
00028
00029 TriggerDecision ();
00036 TriggerDecision (bool l1, bool l2, bool ef);
00037
00038 ~TriggerDecision ();
00039
00040
00041
00042 void print() const;
00043 void printAccepted() const;
00044
00045 bool isDefinedL1() const { return m_L1defined; }
00046 bool isDefinedL2() const { return m_L2defined; }
00047 bool isDefinedEF() const { return m_EFdefined; }
00048 bool isDefined(std::string) const;
00049 bool isDefined(std::string, unsigned int) const;
00050
00051 bool isTriggerPassed() const;
00052 bool isPassedL1() const;
00053 bool isPassedL2() const;
00054 bool isPassedEF() const;
00059 bool isTriggered(std::string name) const;
00060
00066 bool isTriggered(std::string name, unsigned int level) const;
00067
00068
00069
00070 std::vector<std::string> signatures() const;
00071 std::vector<std::string> signatures(unsigned int level) const;
00072
00077 std::map<std::string,bool> L1map() const;
00082 std::map<std::string,bool> L2map() const;
00083
00088 std::map<std::string,bool> EFmap() const;
00089
00093 std::vector<std::string> ignoredSigs() const;
00094
00095
00096 void set_TriggerItem(std::string, bool, unsigned int);
00097 void set_ignore_TriggerItem(std::string);
00098 bool ignore_TriggerItem(std::string);
00099
00100 private:
00101
00102 void print(bool print_all) const;
00103
00104
00105 bool m_L1defined, m_L2defined, m_EFdefined;
00106
00107
00108 std::map<std::string, bool> m_TriggerMapL1;
00109 std::map<std::string, bool> m_TriggerMapL2;
00110 std::map<std::string, bool> m_TriggerMapEF;
00111
00112 std::vector<std::string> m_ignore;
00113
00114 MessageSvcProvider m_messageSvcProvider;
00115
00116 };
00117
00118 CLASS_DEF( TriggerDecision , 28494668, 1 )
00119
00120 #endif