63 msg(MSG:: INFO) <<
"ParentChildwStatusFilter INITIALISING " <<
endmsg;
66 msg(MSG:: ERROR) <<
"PDGParent[] not set " <<
endmsg;
68 msg( MSG:: ERROR) <<
"StatusParent[] not set " <<
endmsg;
70 msg(MSG:: ERROR) <<
"PDGChild[] not set " <<
endmsg;
85 return StatusCode::SUCCESS;
91 return StatusCode::SUCCESS;
101 msg(MSG:: INFO) <<
" ParentChildwStatusFilter filtering " <<
endmsg;
105 const HepMC::GenEvent* genEvt = (*itr);
106 for(
const auto& pitr: *genEvt){
109 int okStatusParent=0;
111 if(std::abs(pitr->pdg_id()) ==
m_PDGParent[
i]) okPDGParent=1;
114 if( ( (
m_PDGParent[0] == 0) || (okPDGParent && okStatusParent))
121 if(!(pitr->end_vertex()))
continue;
123 for(
const auto& thisChild: *(pitr->end_vertex())){
126 if(std::abs(thisChild->pdg_id()) ==
m_PDGChild[
i]) okPDGChild=1;
127 if( (thisChild->pdg_id() != pitr->pdg_id() )
132 return StatusCode::SUCCESS;
139 setFilterPassed(
false);
140 return StatusCode::SUCCESS;