File indexing completed on 2024-04-06 12:04:28
0001 #ifndef L1GlobalTrigger_L1GlobalTriggerReadoutRecord_h
0002 #define L1GlobalTrigger_L1GlobalTriggerReadoutRecord_h
0003
0004
0005
0006
0007
0008
0009
0010
0011
0012
0013
0014
0015
0016
0017
0018
0019
0020 #include <string>
0021 #include <vector>
0022 #include <iosfwd>
0023
0024
0025 #include "DataFormats/L1GlobalTrigger/interface/L1GlobalTriggerReadoutSetupFwd.h"
0026 #include "DataFormats/L1GlobalTrigger/interface/L1GlobalTriggerReadoutSetup.h"
0027
0028 #include "DataFormats/L1GlobalMuonTrigger/interface/L1MuGMTReadoutCollection.h"
0029
0030 #include "DataFormats/L1GlobalTrigger/interface/L1GtfeWord.h"
0031 #include "DataFormats/L1GlobalTrigger/interface/L1GtFdlWord.h"
0032 #include "DataFormats/L1GlobalTrigger/interface/L1GtPsbWord.h"
0033
0034 #include "DataFormats/Common/interface/RefProd.h"
0035
0036 #include "FWCore/Utilities/interface/typedefs.h"
0037
0038
0039 namespace edm {
0040 template <typename T>
0041 class Handle;
0042 }
0043
0044
0045
0046 class L1GlobalTriggerReadoutRecord {
0047 public:
0048
0049 L1GlobalTriggerReadoutRecord();
0050
0051 L1GlobalTriggerReadoutRecord(int NumberBxInEvent);
0052
0053 L1GlobalTriggerReadoutRecord(const int numberBxInEvent, const int numberFdlBoards, const int numberPsbBoards);
0054
0055
0056 L1GlobalTriggerReadoutRecord(const L1GlobalTriggerReadoutRecord&);
0057
0058
0059 virtual ~L1GlobalTriggerReadoutRecord();
0060
0061
0062 L1GlobalTriggerReadoutRecord& operator=(const L1GlobalTriggerReadoutRecord&);
0063
0064
0065 bool operator==(const L1GlobalTriggerReadoutRecord&) const;
0066
0067
0068 bool operator!=(const L1GlobalTriggerReadoutRecord&) const;
0069
0070 public:
0071
0072
0073
0074 const bool decision(int bxInEventValue) const;
0075 const bool decision() const;
0076
0077 const cms_uint16_t finalOR(int bxInEventValue) const;
0078 const cms_uint16_t finalOR() const;
0079
0080 const DecisionWord& decisionWord(int bxInEventValue) const;
0081 const DecisionWord& decisionWord() const;
0082
0083 const TechnicalTriggerWord& technicalTriggerWord(int bxInEventValue) const;
0084 const TechnicalTriggerWord& technicalTriggerWord() const;
0085
0086
0087 void setDecision(const bool& t, int bxInEventValue);
0088 void setDecision(const bool& t);
0089
0090 void setDecisionWord(const DecisionWord& decisionWordValue, int bxInEventValue);
0091 void setDecisionWord(const DecisionWord& decisionWordValue);
0092
0093 void setTechnicalTriggerWord(const TechnicalTriggerWord& ttWordValue, int bxInEventValue);
0094 void setTechnicalTriggerWord(const TechnicalTriggerWord& ttWordValue);
0095
0096
0097 void printGtDecision(std::ostream& myCout, int bxInEventValue) const;
0098 void printGtDecision(std::ostream& myCout) const;
0099
0100
0101 void printTechnicalTrigger(std::ostream& myCout, int bxInEventValue) const;
0102 void printTechnicalTrigger(std::ostream& myCout) const;
0103
0104
0105 const edm::RefProd<L1MuGMTReadoutCollection> muCollectionRefProd() const;
0106 void setMuCollectionRefProd(edm::Handle<L1MuGMTReadoutCollection>&);
0107 void setMuCollectionRefProd(const edm::RefProd<L1MuGMTReadoutCollection>&);
0108
0109
0110
0111
0112
0113
0114
0115 const L1GtfeWord gtfeWord() const;
0116 void setGtfeWord(const L1GtfeWord&);
0117
0118
0119 const std::vector<L1GtFdlWord> gtFdlVector() const { return m_gtFdlWord; }
0120
0121 std::vector<L1GtFdlWord>& gtFdlVector() { return m_gtFdlWord; }
0122
0123
0124 const L1GtFdlWord gtFdlWord(int bxInEventValue) const;
0125 const L1GtFdlWord gtFdlWord() const;
0126
0127 void setGtFdlWord(const L1GtFdlWord&, int bxInEventValue);
0128 void setGtFdlWord(const L1GtFdlWord&);
0129
0130
0131 const std::vector<L1GtPsbWord> gtPsbVector() const { return m_gtPsbWord; }
0132
0133 std::vector<L1GtPsbWord>& gtPsbVector() { return m_gtPsbWord; }
0134
0135
0136 const L1GtPsbWord gtPsbWord(cms_uint16_t boardIdValue, int bxInEventValue) const;
0137 const L1GtPsbWord gtPsbWord(cms_uint16_t boardIdValue) const;
0138
0139 void setGtPsbWord(const L1GtPsbWord&, cms_uint16_t boardIdValue, int bxInEventValue);
0140 void setGtPsbWord(const L1GtPsbWord&, cms_uint16_t boardIdValue);
0141 void setGtPsbWord(const L1GtPsbWord& gtPsbWordValue);
0142
0143
0144
0145
0146 void reset();
0147
0148
0149 void print(std::ostream& myCout) const;
0150
0151
0152 friend std::ostream& operator<<(std::ostream&, const L1GlobalTriggerReadoutRecord&);
0153
0154 private:
0155 L1GtfeWord m_gtfeWord;
0156
0157 std::vector<L1GtFdlWord> m_gtFdlWord;
0158
0159 std::vector<L1GtPsbWord> m_gtPsbWord;
0160
0161 edm::RefProd<L1MuGMTReadoutCollection> m_muCollRefProd;
0162 };
0163
0164 #endif