00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015 #ifndef DECAYMODELBASE_HH
00016 #define DECAYMODELBASE_HH
00017
00018 #include "CLHEP/config/CLHEP.h"
00019 #include <string>
00020 #include <vector>
00021
00022 #define REGISTER_DECAY_MODE(type,config) \
00023 namespace { HepPDT::RegisterMe<type,config> registered##type(#type); }
00024
00025
00026 namespace HepPDT {
00027
00032 template< class CONFIG >
00033 class DecayModelBase {
00034
00035 public:
00036 typedef CONFIG Config;
00037 typedef typename CONFIG::ParticleData PD;
00038 typedef typename CONFIG::PT PT;
00039
00040
00041 virtual ~DecayModelBase() {;}
00042
00043
00044
00045 inline DecayModelBase( const DecayModelBase<CONFIG> & orig ) {;}
00046 inline DecayModelBase & operator = ( const DecayModelBase<CONFIG> & rhs ) { return *this; }
00047 inline void swap( DecayModelBase<CONFIG> & other ) {;}
00048
00049
00050
00051 virtual void decay( const std::vector< PD > & products,
00052 const PT & parent,
00053 std::vector<PT> & daughters ) = 0;
00054
00055
00056 virtual int parameters( std::vector<double> & fillme) const = 0;
00057 virtual std::string name() const = 0;
00058
00059 protected:
00060
00061
00062 DecayModelBase( ) {;}
00063
00064
00065
00066
00067 };
00068
00069 template< class CONFIG >
00070 inline
00071 void swap( DecayModelBase<CONFIG> & first, DecayModelBase<CONFIG> & second ) {
00072 first.swap( second );
00073 }
00074
00075 }
00076
00077 #endif // DECAYMODELBASE_HH
00078