#include <TryToShower.h>
Collaboration diagram for Atlfast::TryToShower:
Public Methods | |
TryToShower (Calorimeter *c) | |
bool | operator() (const TransportedParticle *) |
Private Attributes | |
Calorimeter * | m_calorimeter |
|
Definition at line 19 of file TryToShower.cxx.
00019 :m_calorimeter(c){ 00020 } |
|
Definition at line 21 of file TryToShower.cxx. References Atlfast::Calorimeter::addEelements(), Atlfast::Calorimeter::addHelements(), Atlfast::Calorimeter::gridletForger(), m_calorimeter, Atlfast::Calorimeter::msgStream(), Atlfast::TransportedParticle::particle(), and Atlfast::TransportedParticle::phi().
00021 { 00022 00023 MsgStream& log = m_calorimeter->msgStream(); 00024 00025 const GridletForger* gf = m_calorimeter->gridletForger(); 00026 if(gf == 0) return false; 00027 00028 const HepMC::GenParticle* particle = tp->particle(); 00029 ParticleInfo pi( tp->phi(), 00030 particle->momentum().pseudoRapidity(), 00031 particle->momentum().e(), 00032 particle->pdg_id() 00033 ); 00034 Gridlet* gridlet = gf->makeGridlet(pi); 00035 00036 if(!gridlet) { 00037 // log<<MSG::DEBUG<<"Particle refused by Showerer "<<endl; 00038 return false; 00039 } 00040 // else{ 00041 // log<<MSG::DEBUG<<"Particle accepted by Showerer : gridlet:"<<endl; 00042 // log<<MSG::DEBUG<<gridlet<<endl; 00043 // } 00044 00045 std::vector<GridletElement*> e = gridlet->eElements(); 00046 m_calorimeter->addEelements( e.begin(), e.end() ); 00047 std::vector<GridletElement*> h = gridlet->hElements(); 00048 m_calorimeter->addHelements( h.begin(), h.end() ); 00049 00050 return true; 00051 } |
|
Definition at line 21 of file TryToShower.h. Referenced by operator()(). |