45 inputFile.open(evfile);
51 "G4HEPEvtInterface:: cannot open file.");
61 const char* fn = evfile.
data();
62 inputFile.open((
char*)fn);
68 "G4HEPEvtInterface:: cannot open file.");
84 G4Exception(
"G4HEPEvtInterface::GeneratePrimaryVertex",
"Event0202",
89 for(
G4int IHEP=0; IHEP<NHEP; IHEP++ )
100 inputFile >> ISTHEP >> IDHEP >> JDAHEP1 >> JDAHEP2
101 >> PHEP1 >> PHEP2 >> PHEP3 >> PHEP5;
107 particle->
SetMomentum(PHEP1*GeV, PHEP2*GeV, PHEP3*GeV );
114 HPlist.push_back( hepParticle );
118 if( HPlist.size() == 0 )
return;
122 for(
size_t i=0; i<HPlist.size(); i++ )
124 if( HPlist[i]->GetJDAHEP1() > 0 )
126 G4int jda1 = HPlist[i]->GetJDAHEP1()-1;
127 G4int jda2 = HPlist[i]->GetJDAHEP2()-1;
129 for(
G4int j=jda1; j<=jda2; j++ )
132 if(HPlist[j]->GetISTHEP()>0)
145 for(
size_t ii=0; ii<HPlist.size(); ii++ )
147 if( HPlist[ii]->GetISTHEP() > 0 )
157 for(
size_t iii=0;iii<HPlist.size();iii++)
158 {
delete HPlist[iii]; }