Back to home page

Project CMSSW displayed by LXR

 
 

    


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

0001 #ifndef L1Trigger_L1JetParticle_h
0002 #define L1Trigger_L1JetParticle_h
0003 // -*- C++ -*-
0004 //
0005 // Package:     L1Trigger
0006 // Class  :     L1JetParticle
0007 //
0008 /**\class L1JetParticle \file L1JetParticle.h DataFormats/L1Trigger/interface/L1JetParticle.h \author Werner Sun
0009 
0010  Description: L1Extra particle class for jet objects.
0011 */
0012 //
0013 // Original Author:  Werner Sun
0014 //         Created:  Sat Jul 15 12:41:07 EDT 2006
0015 //
0016 
0017 // system include files
0018 
0019 // user include files
0020 #include "DataFormats/Candidate/interface/LeafCandidate.h"
0021 #include "DataFormats/L1GlobalCaloTrigger/interface/L1GctCollections.h"
0022 #include "DataFormats/Common/interface/Ref.h"
0023 
0024 // forward declarations
0025 
0026 namespace l1extra {
0027 
0028   class L1JetParticle : public reco::LeafCandidate {
0029   public:
0030     enum JetType { kCentral, kForward, kTau, kUndefined, kNumOfJetTypes };
0031 
0032     L1JetParticle();
0033 
0034     L1JetParticle(const LorentzVector& p4, const edm::Ref<L1GctJetCandCollection>& aRef, int bx = 0);
0035 
0036     L1JetParticle(const PolarLorentzVector& p4, const edm::Ref<L1GctJetCandCollection>& aRef, int bx = 0);
0037 
0038     // Creates null Ref.
0039     L1JetParticle(const LorentzVector& p4, JetType type = kUndefined, int bx = 0);
0040 
0041     L1JetParticle(const PolarLorentzVector& p4, JetType type = kUndefined, int bx = 0);
0042 
0043     ~L1JetParticle() override {}
0044 
0045     // ---------- const member functions ---------------------
0046     JetType type() const { return type_; }
0047 
0048     const edm::Ref<L1GctJetCandCollection>& gctJetCandRef() const { return ref_; }
0049 
0050     const L1GctJetCand* gctJetCand() const { return ref_.get(); }
0051 
0052     L1JetParticle* clone() const override { return new L1JetParticle(*this); }
0053 
0054     int bx() const { return bx_; }
0055 
0056     // ---------- static member functions --------------------
0057 
0058     // ---------- member functions ---------------------------
0059     void setType(JetType type) { type_ = type; }
0060 
0061     void setBx(int bx) { bx_ = bx; }
0062 
0063   private:
0064     // L1JetParticle(const L1JetParticle&); // stop default
0065 
0066     // const L1JetParticle& operator=(const L1JetParticle&); // stop default
0067 
0068     // ---------- member data --------------------------------
0069     JetType type_;
0070     edm::Ref<L1GctJetCandCollection> ref_;
0071     int bx_;
0072   };
0073 }  // namespace l1extra
0074 
0075 #endif