CMS 3D CMS Logo

/data/refman/pasoursint/CMSSW_4_4_5_patch3/src/DataFormats/L1Trigger/interface/L1JetParticle.h

Go to the documentation of this file.
00001 #ifndef L1Trigger_L1JetParticle_h
00002 #define L1Trigger_L1JetParticle_h
00003 // -*- C++ -*-
00004 //
00005 // Package:     L1Trigger
00006 // Class  :     L1JetParticle
00007 // 
00012 //
00013 // Original Author:  Werner Sun
00014 //         Created:  Sat Jul 15 12:41:07 EDT 2006
00015 // $Id: L1JetParticle.h,v 1.12 2008/04/03 03:37:20 wsun Exp $
00016 //
00017 
00018 // system include files
00019 
00020 // user include files
00021 #include "DataFormats/Candidate/interface/LeafCandidate.h"
00022 #include "DataFormats/L1GlobalCaloTrigger/interface/L1GctCollections.h"
00023 #include "DataFormats/Common/interface/Ref.h"
00024 
00025 // forward declarations
00026 
00027 namespace l1extra {
00028 
00029    class L1JetParticle : public reco::LeafCandidate
00030    {
00031 
00032       public:
00033          enum JetType
00034          {
00035             kCentral,
00036             kForward,
00037             kTau,
00038             kUndefined,
00039             kNumOfJetTypes
00040          } ;
00041 
00042          L1JetParticle();
00043 
00044          L1JetParticle( const LorentzVector& p4,
00045                         const edm::Ref< L1GctJetCandCollection >& aRef,
00046                         int bx = 0 ) ;
00047 
00048          L1JetParticle( const PolarLorentzVector& p4,
00049                         const edm::Ref< L1GctJetCandCollection >& aRef,
00050                         int bx = 0 ) ;
00051 
00052          // Creates null Ref.
00053          L1JetParticle( const LorentzVector& p4,
00054                         JetType type = kUndefined,
00055                         int bx = 0 ) ;
00056 
00057          L1JetParticle( const PolarLorentzVector& p4,
00058                         JetType type = kUndefined,
00059                         int bx = 0 ) ;
00060 
00061          virtual ~L1JetParticle() {}
00062 
00063          // ---------- const member functions ---------------------
00064          JetType type() const
00065          { return type_ ; }
00066 
00067          const edm::Ref< L1GctJetCandCollection >& gctJetCandRef() const
00068          { return ref_ ; }
00069 
00070          const L1GctJetCand* gctJetCand() const
00071          { return ref_.get() ; }
00072 
00073          virtual L1JetParticle* clone() const
00074          { return new L1JetParticle( *this ) ; }
00075 
00076          int bx() const
00077          { return bx_ ; }
00078 
00079          // ---------- static member functions --------------------
00080 
00081          // ---------- member functions ---------------------------
00082          void setType( JetType type )
00083          { type_ = type ; }
00084 
00085          void setBx( int bx )
00086          { bx_ = bx ; }
00087 
00088       private:
00089          // L1JetParticle(const L1JetParticle&); // stop default
00090 
00091          // const L1JetParticle& operator=(const L1JetParticle&); // stop default
00092 
00093          // ---------- member data --------------------------------
00094          JetType type_ ;
00095          edm::Ref< L1GctJetCandCollection > ref_ ;
00096          int bx_ ;
00097    };
00098 }
00099 
00100 #endif