00001
00002 #ifndef RIVET_Particle_HH
00003 #define RIVET_Particle_HH
00004
00005 #include "Rivet/Rivet.hh"
00006 #include "HepMC/GenParticle.h"
00007 #include "Rivet/Particle.fhh"
00008 #include "Rivet/RivetCLHEP.fhh"
00009
00010
00011 namespace Rivet {
00012
00013 typedef HepMC::GenParticle GenParticle;
00014
00015
00016
00017 class Particle {
00018 public:
00019
00020
00021 inline Particle() :
00022 _original(0), _id(0), _momentum(0), _mass(0.0)
00023 { };
00024
00025
00026 Particle(const GenParticle& gp);
00027
00028
00029 Particle(const Particle& p);
00030
00031
00032 ~Particle();
00033
00034
00035 Particle& operator=(const Particle& p);
00036
00037
00038 public:
00039
00040 inline const GenParticle& getHepMCParticle() const { return *_original; }
00041
00042
00043 inline bool hasHepMCParticle() const { return _original; }
00044
00045
00046 inline const long getPdgId() const { return _id; }
00047
00048
00049 inline CLHEP::LorentzVector& getMomentum() { return *_momentum; }
00050
00051
00052 inline const CLHEP::LorentzVector& getMomentum() const { return *_momentum; }
00053
00054
00055 inline const double getMass() const { return _mass; }
00056
00057
00058 private:
00059
00060
00061 const GenParticle* _original;
00062
00063
00064 long _id;
00065
00066
00067 CLHEP::LorentzVector* _momentum;
00068
00069
00070 double _mass;
00071
00072 };
00073
00074 }
00075
00076 #endif