Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2024-04-06 12:04:38

0001 #ifndef DataFormats_L1Trigger_ETSum_h
0002 #define DataFormats_L1Trigger_ETSum_h
0003 
0004 #include "DataFormats/L1Trigger/interface/L1Candidate.h"
0005 #include "DataFormats/L1Trigger/interface/BXVector.h"
0006 #include "DataFormats/L1Trigger/interface/L1TObjComparison.h"
0007 
0008 namespace l1t {
0009 
0010   class EtSum;
0011   typedef BXVector<EtSum> EtSumBxCollection;
0012   typedef edm::Ref<EtSumBxCollection> EtSumRef;
0013   typedef edm::RefVector<EtSumBxCollection> EtSumRefVector;
0014   typedef std::vector<EtSumRef> EtSumVectorRef;
0015   // Phase-2
0016   typedef std::vector<EtSum> EtSumP2Collection;
0017   typedef edm::Ref<EtSumP2Collection> EtSumP2Ref;
0018   typedef edm::RefVector<EtSumP2Collection> EtSumP2RefVector;
0019   typedef std::vector<EtSumP2Ref> EtSumVectorP2Ref;
0020 
0021   typedef ObjectRefBxCollection<EtSum> EtSumRefBxCollection;
0022   typedef ObjectRefPair<EtSum> EtSumRefPair;
0023   typedef ObjectRefPairBxCollection<EtSum> EtSumRefPairBxCollection;
0024 
0025   class EtSum : public L1Candidate {
0026   public:
0027     enum EtSumType {
0028       kTotalEt,
0029       kTotalHt,
0030       kMissingEt,
0031       kMissingHt,
0032       kTotalEtx,
0033       kTotalEty,
0034       kTotalHtx,
0035       kTotalHty,
0036       kMissingEtHF,
0037       kTotalEtxHF,
0038       kTotalEtyHF,
0039       kMinBiasHFP0,
0040       kMinBiasHFM0,
0041       kMinBiasHFP1,
0042       kMinBiasHFM1,
0043       kTotalEtHF,
0044       kTotalEtEm,
0045       kTotalHtHF,
0046       kTotalHtxHF,
0047       kTotalHtyHF,
0048       kMissingHtHF,
0049       kTowerCount,
0050       kCentrality,
0051       kAsymEt,
0052       kAsymHt,
0053       kAsymEtHF,
0054       kAsymHtHF,
0055       kZDCP,
0056       kZDCM,
0057       kUninitialized
0058     };
0059 
0060     EtSum() : type_{kUninitialized} {}
0061     explicit EtSum(EtSumType type) : type_{type} {}
0062 
0063     EtSum(const LorentzVector& p4, EtSumType type, int pt = 0, int eta = 0, int phi = 0, int qual = 0);
0064 
0065     EtSum(const PolarLorentzVector& p4, EtSumType type, int pt = 0, int eta = 0, int phi = 0, int qual = 0);
0066 
0067     ~EtSum() override;
0068 
0069     void setType(EtSumType type);
0070 
0071     EtSumType getType() const;
0072 
0073     virtual bool operator==(const l1t::EtSum& rhs) const;
0074     virtual inline bool operator!=(const l1t::EtSum& rhs) const { return !(operator==(rhs)); };
0075 
0076   private:
0077     // type of EtSum
0078     EtSumType type_;
0079 
0080     // additional hardware quantities common to L1 global EtSum
0081     // there are currently none
0082   };
0083 
0084 }  // namespace l1t
0085 
0086 #endif