Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2024-04-06 12:19:59

0001 #ifndef GlobalTrigger_L1GtMuonCondition_h
0002 #define GlobalTrigger_L1GtMuonCondition_h
0003 
0004 /**
0005  * \class L1GtMuonCondition
0006  *
0007  *
0008  * Description: evaluation of a CondMuon condition.
0009  *
0010  * Implementation:
0011  *    <TODO: enter implementation details>
0012  *
0013  * \author: Vasile Mihai Ghete   - HEPHY Vienna
0014  *
0015  *
0016  */
0017 
0018 // system include files
0019 #include <iosfwd>
0020 #include <string>
0021 
0022 // user include files
0023 //   base classes
0024 #include "L1Trigger/GlobalTrigger/interface/L1GtConditionEvaluation.h"
0025 
0026 // forward declarations
0027 class L1GtCondition;
0028 class L1GtMuonTemplate;
0029 
0030 class L1MuGMTCand;
0031 
0032 class L1GlobalTriggerGTL;
0033 
0034 // class declaration
0035 class L1GtMuonCondition : public L1GtConditionEvaluation {
0036 public:
0037   /// constructors
0038   ///     default
0039   L1GtMuonCondition();
0040 
0041   ///     from base template condition (from event setup usually)
0042   L1GtMuonCondition(const L1GtCondition *, const L1GlobalTriggerGTL *, const int nrL1Mu, const int ifMuEtaNumberBits);
0043 
0044   // copy constructor
0045   L1GtMuonCondition(const L1GtMuonCondition &);
0046 
0047   // destructor
0048   ~L1GtMuonCondition() override;
0049 
0050   // assign operator
0051   L1GtMuonCondition &operator=(const L1GtMuonCondition &);
0052 
0053 public:
0054   /// the core function to check if the condition matches
0055   const bool evaluateCondition() const override;
0056 
0057   /// print condition
0058   void print(std::ostream &myCout) const override;
0059 
0060 public:
0061   ///   get / set the pointer to a L1GtCondition
0062   inline const L1GtMuonTemplate *gtMuonTemplate() const { return m_gtMuonTemplate; }
0063 
0064   void setGtMuonTemplate(const L1GtMuonTemplate *);
0065 
0066   ///   get / set the pointer to GTL
0067   inline const L1GlobalTriggerGTL *gtGTL() const { return m_gtGTL; }
0068 
0069   void setGtGTL(const L1GlobalTriggerGTL *);
0070 
0071   ///   get / set the number of bits for eta of muon objects
0072   inline const int gtIfMuEtaNumberBits() const { return m_ifMuEtaNumberBits; }
0073 
0074   void setGtIfMuEtaNumberBits(const int &);
0075 
0076   ///   get / set maximum number of bins for the delta phi scales
0077   inline const int gtCorrParDeltaPhiNrBins() const { return m_corrParDeltaPhiNrBins; }
0078 
0079   void setGtCorrParDeltaPhiNrBins(const int &);
0080 
0081 private:
0082   /// copy function for copy constructor and operator=
0083   void copy(const L1GtMuonCondition &cp);
0084 
0085   /// load muon candidates
0086   const L1MuGMTCand *getCandidate(const int indexCand) const;
0087 
0088   /// function to check a single object if it matches a condition
0089   const bool checkObjectParameter(const int iCondition, const L1MuGMTCand &cand) const;
0090 
0091 private:
0092   /// pointer to a L1GtMuonTemplate
0093   const L1GtMuonTemplate *m_gtMuonTemplate;
0094 
0095   /// pointer to GTL, to be able to get the trigger objects
0096   const L1GlobalTriggerGTL *m_gtGTL;
0097 
0098   /// number of bits for eta of muon objects
0099   int m_ifMuEtaNumberBits;
0100 
0101   // maximum number of bins for the delta phi scales
0102   unsigned int m_corrParDeltaPhiNrBins;
0103 };
0104 
0105 #endif