/home/bes3soft/bes3soft/Boss/7.0.2/dist/7.0.2/Reconstruction/MdcPatRec/MdcRecoUtil/MdcRecoUtil-00-01-08/MdcRecoUtil/PdtEntry.h

Go to the documentation of this file.
00001 //                              -*- Mode: C++ -*- 
00002 //
00003 // PdtEntry.h - data class for a particle
00004 //
00005 // Copyright (C)  1993  The Board of Trustees of The Leland Stanford
00006 // 
00007 // History:
00008 //      Migration for BESIII MDC
00009 //                      Junior University.  All Rights Reserved.
00010 //
00011 // $Id: PdtEntry.h,v 1.2 2009/12/23 02:59:56 zhangy Exp $
00012 //
00013 // A PdtEntry is an almost pure data class. It holds the data for a particle,
00014 // ie. mass, width, lifetime, decay modes, etc. The sign of quantities is
00015 // defined to be that of the particle (not antiparticle).
00016 //
00017 // Modified:
00018 //    Luca Lista     04 oct 96    lookup by different types, not by integer
00019 //
00020 // See Also
00021 //    AntiPData, PData, Pdt, DecayMode
00022 
00023 #ifndef _PDTENTRY_HH_
00024 #define _PDTENTRY_HH_
00025 
00026 #include "MdcRecoUtil/PdtLund.h"
00027 #include "MdcRecoUtil/PdtPdg.h"
00028 #include "MdcRecoUtil/PdtGeant.h"
00029 #include "MdcRecoUtil/PdtPid.h"
00030 #include <vector>
00031 using std::vector;
00032 
00033 #include <iosfwd>
00034 class DecayMode;
00035 
00036 class PdtEntry
00037 {
00038 public:
00039   // in the constructor, spin is in units of hbar, charge in unit of e.
00040   // mass and width are in GeV.
00041   PdtEntry(const char *name, PdtLund::LundType code, float spin,
00042            float charge, float mass, float width=0, float massCut=0);
00043   PdtEntry(const char *name, PdtGeant::GeantType code, float spin,
00044            float charge, float mass, float width=0, float massCut=0);
00045   PdtEntry(const char *name, PdtPdg::PdgType code, float spin,
00046            float charge, float mass, float width=0, float massCut=0);
00047   
00048   virtual ~PdtEntry();
00049   
00050   void printOn(std::ostream& str) const;
00051   void printBFOn(std::ostream& str) const;
00052   
00053   const char *name()     const {return _name;}
00054   float       charge()   const {return _charge;}
00055   float       mass()     const {return _mass;}
00056   float       width()    const {return _width;}
00057   float       widthCut() const {return _widthCut;}
00058   float       lifetime() const {return _lifetime;}
00059   float       spin()     const {return _spin;}
00060   float       sumBR()    const {return _sumBR;}
00061   const vector<DecayMode*> *decayList() const { return _decayList; }
00062   void addDecay(float bf, vector<PdtEntry*> *kids );
00063   PdtLund::LundType   lundId()  const { return _lundId;};
00064   PdtPdg::PdgType     pdgId()   const { return _pdgId; }
00065   PdtGeant::GeantType geantId() const { return _geantId; };
00066   PdtPid::PidType     pidId() const   { return _pidId; };
00067   PdtPid::PidNeutralType    pidNeutId() const   { return _pidNeutId; };
00068   bool operator==(const PdtEntry &) const;
00069   bool operator<(const PdtEntry &) const;
00070   
00071   // new functionality (GHM 05/99) : get the conjugate PdtEntry
00072   const PdtEntry* conjugate() const;
00073 
00074 protected:
00075   char *_name;                  // name
00076   float _mass;          // nominal mass (GeV)
00077   float _width;         // width (0 if stable) (GeV)
00078   float _lifetime;              // c*tau, in standard length units (cm)
00079   float _spin;          // spin, in units of hbar
00080   float _charge;                // charge, in units of e
00081   float _widthCut;              // used to limit range of B-W
00082   float _sumBR;         // total branching ratio (should be 1.)
00083   vector<DecayMode*>* _decayList; // pointer to linked list of decayers
00084   PdtLund::LundType   _lundId;
00085   PdtPdg::PdgType     _pdgId;
00086   PdtGeant::GeantType _geantId;
00087   PdtPid::PidType     _pidId;
00088   PdtPid::PidNeutralType  _pidNeutId;
00089   /*mutable*/ const PdtEntry* _conjugate; // this particle conjugate
00090 };
00091 
00092 #endif

Generated on Tue Nov 29 23:13:31 2016 for BOSS_7.0.2 by  doxygen 1.4.7