CMS 3D CMS Logo

/data/doxygen/doxygen-1.7.3/gen/CMSSW_4_2_8/src/DataFormats/RecoCandidate/interface/CaloRecHitCandidate.h

Go to the documentation of this file.
00001 #ifndef RecoCandidate_CaloRecHitCandidate_h
00002 #define RecoCandidate_CaloRecHitCandidate_h
00003 
00012 #include "DataFormats/RecoCandidate/interface/RecoCandidate.h"
00013 #include "DataFormats/CaloRecHit/interface/CaloRecHit.h"
00014 #include "DataFormats/Common/interface/RefToBase.h"
00015 
00016 namespace reco {
00017 
00018   class CaloRecHitCandidate : public LeafCandidate {
00019   public:
00020     typedef edm::RefToBase<CaloRecHit> CaloRecHitRef;
00022     CaloRecHitCandidate() : LeafCandidate() { }
00024     CaloRecHitCandidate( const LorentzVector & p4, Charge q = 0, const Point & vtx = Point( 0, 0, 0 ) ) :
00025       LeafCandidate( q, p4, vtx ) { }
00027     CaloRecHitCandidate( const PolarLorentzVector & p4, Charge q = 0, const Point & vtx = Point( 0, 0, 0 ) ) :
00028       LeafCandidate( q, p4, vtx ) { }
00030     virtual ~CaloRecHitCandidate();
00032     virtual CaloRecHitCandidate * clone() const;
00034     void setCaloRecHit( const CaloRecHitRef & r ) { caloRecHit_ = r; }
00036     CaloRecHitRef caloRecHit() const { return caloRecHit_; }
00037 
00038   private:
00040     virtual bool overlap( const Candidate & ) const;
00042     CaloRecHitRef caloRecHit_;
00043   };
00045   GET_DEFAULT_CANDIDATE_COMPONENT( CaloRecHitCandidate, edm::RefToBase<CaloRecHit>, caloRecHit );
00046 
00047 }
00048 
00049 #endif