Back to home page

Project CMSSW displayed by LXR

 
 

    


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

0001 //
0002 //
0003 
0004 #ifndef DataFormats_PatCandidates_Particle_h
0005 #define DataFormats_PatCandidates_Particle_h
0006 
0007 /**
0008   \class    pat::Particle Particle.h "DataFormats/PatCandidates/interface/Particle.h"
0009   \brief    Analysis-level particle class
0010 
0011    Particle implements an analysis-level particle class within the 'pat'
0012    namespace.
0013 
0014   \author   Steven Lowette, Giovanni Petrucciani
0015 */
0016 
0017 #include "DataFormats/Candidate/interface/LeafCandidate.h"
0018 #include "DataFormats/PatCandidates/interface/PATObject.h"
0019 
0020 // Define typedefs for convenience
0021 namespace pat {
0022   class Particle;
0023   typedef std::vector<Particle> ParticleCollection;
0024   typedef edm::Ref<ParticleCollection> ParticleRef;
0025   typedef edm::RefVector<ParticleCollection> ParticleRefVector;
0026 }  // namespace pat
0027 
0028 namespace pat {
0029 
0030   class Particle : public PATObject<reco::LeafCandidate> {
0031   public:
0032     /// default constructor
0033     Particle();
0034     /// constructor from a LeafCandidate
0035     Particle(const reco::LeafCandidate& aParticle);
0036     /// destructor
0037     ~Particle() override;
0038 
0039     /// required reimplementation of the Candidate's clone method
0040     Particle* clone() const override { return new Particle(*this); }
0041   };
0042 
0043 }  // namespace pat
0044 
0045 #endif