rivet is hosted by Hepforge, IPPP Durham
ChargedLeptons.hh
Go to the documentation of this file.
00001 // -*- C++ -*-
00002 #ifndef RIVET_ChargedLeptons_HH
00003 #define RIVET_ChargedLeptons_HH
00004 
00005 #include "Rivet/Projection.hh"
00006 #include "Rivet/Projections/ChargedFinalState.hh"
00007 #include "Rivet/Particle.hh"
00008 #include "Rivet/Event.hh"
00009 
00010 namespace Rivet {
00011 
00012 
00013   /// @brief Get charged final-state leptons
00014   ///
00015   /// NB. This is just electrons and muons, unless you set taus stable!
00016   class ChargedLeptons : public FinalState {
00017   public:
00018 
00019     /// Constructor
00020     ChargedLeptons(const FinalState& fsp)
00021     {
00022       setName("ChargedLeptons");
00023       addProjection(ChargedFinalState(fsp), "ChFS");
00024     }
00025 
00026     /// Clone on the heap.
00027     virtual const Projection* clone() const {
00028       return new ChargedLeptons(*this);
00029     }
00030 
00031   protected:
00032 
00033     /// Apply the projection to the event.
00034     void project(const Event& evt);
00035 
00036     /// Compare projections.
00037     int compare(const Projection& other) const;
00038 
00039   public:
00040 
00041     /// Access the projected leptons.
00042     const Particles& chargedLeptons() const {
00043       return _theParticles;
00044     }
00045 
00046   };
00047 
00048 
00049 }
00050 
00051 #endif