00001 #include <vector> 00002 00003 #include "TruthHelper/IsGenerator.h" 00004 #include "HepMC/GenParticle.h" 00005 using std::vector; 00006 using std::abs; 00007 00008 //**************************************************************** 00009 //* IsGenerator * 00010 //**************************************************************** 00011 IsGenerator::IsGenerator() {} 00012 00013 bool IsGenerator::operator()( const Particle* const p ) const { 00014 return ( p->barcode() < 100000 && ( p->status()<200 || 00015 p->status()%1000 == 1 || 00016 p->status()%1000 == 2 ) ) ? true:false; 00017 // conforms to PDG standard and accomodates the generated partilces that are copied to kine 00018 } 00019 00020 bool IsGenerator::operator() ( const Particle& p ) const { 00021 return this->operator()(&p); 00022 } 00023 GenIMCselector* IsGenerator::create() const {return new IsGenerator(*this);} 00024