CLHEP/HepPDT/NullDecayModelT.hh

00001 // $Id: NullDecayModelT.hh,v 1.4 2002/04/18 20:15:21 garren Exp $
00002 // ----------------------------------------------------------------------
00003 //
00004 // NullDecayModelT.hh
00005 // Author:  Lynn Garren, Walter Brown, Marc Paterno
00006 //
00007 // Note: users' decay models inheriting from this class must have
00008 //  an explicit constructor that takes a const reference to a vector of doubles
00009 //  as well as implentations of all methods declared pure virtual.
00010 // User code will need :
00011 //     #include "CLHEP/HepPDT/NullDecayModelT.hh"
00012 //     REGISTER_DECAY_MODE(ModeA,ModeA::Config)
00013 //
00014 // ----------------------------------------------------------------------
00015 #ifndef NULLDECAYMODELT_HH
00016 #define NULLDECAYMODELT_HH
00017 
00018 #include "CLHEP/config/CLHEP.h"
00019 #include "CLHEP/HepPDT/DecayModelBase.hh"
00020 
00021 namespace HepPDT {
00022 
00027 template< class Config >
00028 class NullDecayModelT  : public DecayModelBase<Config> {
00029 
00030 public:
00031   typedef typename Config::ParticleData PD;     // ParticleDataType
00032   typedef typename Config::PT           PT;     // ParticleType
00033 
00034   // ---  birth/death:
00035   NullDecayModelT( std::vector<double> const & /*decayModelParameters*/ ) {;}
00036   virtual ~NullDecayModelT() {;}
00037 
00038   // ---  copying:
00039   //
00040   inline NullDecayModelT( const NullDecayModelT<Config> & /*orig*/ ) {;}
00041   inline NullDecayModelT &  operator = ( const NullDecayModelT<Config> & /*rhs*/ ) { return *this; }
00042   inline void swap( NullDecayModelT<Config> & /*other*/ ) {;}
00043 
00044   // --- decay method placeholder
00045   //
00046   virtual void decay( const std::vector< PD > & /*products*/,
00047                       const PT                & /*parent*/,
00048                       std::vector<PT>         & /*daughters*/ ) {;}
00049    
00050   // accessor placeholders
00051   virtual int         parameters( std::vector<double> & /*fillme*/) const { return 0; }
00052   virtual std::string name() const { return "NullDecayModelT<>"; }
00053 
00054 };  // NullDecayModelT
00055 
00056 template< class Config >
00057 inline 
00058 void  swap( NullDecayModelT<Config> & first, NullDecayModelT<Config> & second ) {
00059   first.swap( second );
00060 }
00061 
00062 }       // HepPDT
00063 
00064 #endif // NULLDECAYMODELT_HH
00065 

Class Library for High Energy Physics (version 1.8)