Back to home page

Project CMSSW displayed by LXR

 
 

    


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

0001 //-------------------------------------------------
0002 //
0003 /** \class L1MuGMTPSB
0004  *  L1 Global Muon Trigger Pipelined Synchronising Buffer module. 
0005  *
0006  *                the PSB receives muon candidates
0007  *                from the barrel track finder, the endcap track finder
0008  *                and from the RPC trigger. In addition it gets
0009  *                isolation and mip bits from the 
0010  *                regional Calorimeter Trigger
0011 */
0012 //
0013 //
0014 //   Author :
0015 //   N. Neumeister            CERN EP
0016 //
0017 //   Migrated to CMSSW:
0018 //   I. Mikulec
0019 //
0020 //--------------------------------------------------
0021 #ifndef L1TriggerGlobalMuonTrigger_L1MuGMTPSB_h
0022 #define L1TriggerGlobalMuonTrigger_L1MuGMTPSB_h
0023 
0024 //---------------
0025 // C++ Headers --
0026 //---------------
0027 
0028 #include <vector>
0029 
0030 //----------------------
0031 // Base Class Headers --
0032 //----------------------
0033 
0034 #include "FWCore/Framework/interface/Event.h"
0035 #include "DataFormats/L1GlobalMuonTrigger/interface/L1MuRegionalCand.h"
0036 #include "L1Trigger/GlobalMuonTrigger/src/L1MuGMTMatrix.h"
0037 #include "FWCore/Framework/interface/ConsumesCollector.h"
0038 
0039 //------------------------------------
0040 // Collaborating Class Declarations --
0041 //------------------------------------
0042 
0043 class L1MuGlobalMuonTrigger;
0044 
0045 //              ---------------------
0046 //              -- Class Interface --
0047 //              ---------------------
0048 
0049 class L1MuGMTPSB {
0050 public:
0051   /// constructor
0052   L1MuGMTPSB(const L1MuGlobalMuonTrigger& gmt, edm::ConsumesCollector&& iC);
0053 
0054   /// destructor
0055   virtual ~L1MuGMTPSB();
0056 
0057   /// receive muon candidates
0058   void receiveData(edm::Event& e, int bx);
0059 
0060   /// clear PSB
0061   void reset();
0062 
0063   /// print PSB
0064   void print() const;
0065 
0066   /// get RPC muon
0067   const L1MuRegionalCand* RPCMuon(int index) const;
0068 
0069   /// get DTBX muon
0070   const L1MuRegionalCand* DTBXMuon(int index) const;
0071 
0072   /// get CSC muon
0073   const L1MuRegionalCand* CSCMuon(int index) const;
0074 
0075   /// return number of non-empty RPC muons
0076   int numberRPC() const;
0077 
0078   /// return number of non-empty DTBX muons
0079   int numberDTBX() const;
0080 
0081   /// return number of non-empty CSC muons
0082   int numberCSC() const;
0083 
0084   /// are there any data in the PSB
0085   bool empty() const;
0086 
0087   /// return isolation bits
0088   const L1MuGMTMatrix<bool>& isolBits() const { return m_Isol; }
0089 
0090   /// return minimum ionizing bits
0091   const L1MuGMTMatrix<bool>& mipBits() const { return m_Mip; }
0092 
0093 private:
0094   /// get muons from RPCb Trigger
0095   void getRPCb(std::vector<L1MuRegionalCand> const* data, int bx);
0096 
0097   /// get muons from RPCf Trigger
0098   void getRPCf(std::vector<L1MuRegionalCand> const* data, int bx);
0099 
0100   /// get muons from barrel Muon Trigger Track Finder
0101   void getDTBX(std::vector<L1MuRegionalCand> const* data, int bx);
0102 
0103   /// get muons from endcap Muon Trigger Track Finder
0104   void getCSC(std::vector<L1MuRegionalCand> const* data, int bx);
0105 
0106   /// get Calorimeter Trigger data
0107   void getCalo(edm::Event& e);
0108 
0109   /// print barrel RPC muons
0110   void printRPCbarrel() const;
0111 
0112   /// print endcap RPC muons
0113   void printRPCendcap() const;
0114 
0115   /// print DTBX muons
0116   void printDTBX() const;
0117 
0118   /// print CSC muons
0119   void printCSC() const;
0120 
0121 private:
0122   const L1MuGlobalMuonTrigger& m_gmt;
0123 
0124   std::vector<L1MuRegionalCand> m_RpcMuons;
0125   std::vector<L1MuRegionalCand> m_DtbxMuons;
0126   std::vector<L1MuRegionalCand> m_CscMuons;
0127 
0128   L1MuGMTMatrix<bool> m_Isol;
0129   L1MuGMTMatrix<bool> m_Mip;
0130 };
0131 
0132 #endif