Import Geant4 0.1.0 source tree

This commit is contained in:
Gabriele Cosmo
2016-06-08 15:09:25 +02:00
parent b97f8d0df7
commit aaa409b6ee
2922 changed files with 55107 additions and 81674 deletions
+20 -11
View File
@@ -5,8 +5,8 @@
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: ExN03EventAction.cc,v 2.5 1998/10/30 14:41:00 maire Exp $
// GEANT4 tag $Name: geant4-00 $
// $Id: ExN03EventAction.cc,v 1.3 1999/04/16 11:55:08 kurasige Exp $
// GEANT4 tag $Name: geant4-00-01 $
//
//
@@ -31,11 +31,13 @@
#include "G4UImanager.hh"
#include "G4ios.hh"
#include "G4UnitsTable.hh"
#include "Randomize.hh"
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
ExN03EventAction::ExN03EventAction()
:calorimeterCollID(-1),drawFlag("all"),eventMessenger(NULL)
:calorimeterCollID(-1),drawFlag("all"),eventMessenger(NULL),
printModulo(10000)
{
eventMessenger = new ExN03EventActionMessenger(this);
}
@@ -49,20 +51,27 @@ ExN03EventAction::~ExN03EventAction()
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
void ExN03EventAction::BeginOfEventAction()
{ if(calorimeterCollID==-1)
{
void ExN03EventAction::BeginOfEventAction(const G4Event* evt)
{
G4int evtNb = evt->GetEventID();
if (evtNb%printModulo == 0)
{
G4cout << "\n---> Event: " << evtNb << endl;
HepRandom::showEngineStatus();
}
if (calorimeterCollID==-1)
{
G4SDManager * SDman = G4SDManager::GetSDMpointer();
calorimeterCollID = SDman->GetCollectionID("CalCollection");
}
}
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
void ExN03EventAction::EndOfEventAction()
void ExN03EventAction::EndOfEventAction(const G4Event* evt)
{
const G4Event* evt = fpEventManager->GetConstCurrentEvent();
G4cout << ">>> Event " << evt->GetEventID() << endl;
G4HCofThisEvent* HCE = evt->GetHCofThisEvent();
@@ -102,7 +111,7 @@ void ExN03EventAction::EndOfEventAction()
if(G4VVisManager::GetConcreteInstance())
{
for(G4int i=0; i<n_trajectories; i++)
{ G4Trajectory* trj = (*(evt->GetTrajectoryContainer()))[i];
{ G4Trajectory* trj = (G4Trajectory *)((*(evt->GetTrajectoryContainer()))[i]);
if (drawFlag == "all") trj->DrawTrajectory(50);
else if ((drawFlag == "charged")&&(trj->GetCharge() != 0.))
trj->DrawTrajectory(50);