musrEventAction Class Reference

#include <musrEventAction.hh>

List of all members.

Public Member Functions

 musrEventAction ()
 ~musrEventAction ()
void BeginOfEventAction (const G4Event *)
void EndOfEventAction (const G4Event *)


Detailed Description

Definition at line 12 of file musrEventAction.hh.


Constructor & Destructor Documentation

musrEventAction::musrEventAction  ) 
 

Definition at line 14 of file musrEventAction.cc.

00015 {}

musrEventAction::~musrEventAction  ) 
 

Definition at line 19 of file musrEventAction.cc.

00020 {}


Member Function Documentation

void musrEventAction::BeginOfEventAction const G4Event *   ) 
 

Definition at line 24 of file musrEventAction.cc.

00025 {}

void musrEventAction::EndOfEventAction const G4Event *   ) 
 

Definition at line 29 of file musrEventAction.cc.

00030 {
00031   G4int event_id = evt->GetEventID();
00032   
00033   // get number of stored trajectories
00034   //
00035   G4TrajectoryContainer* trajectoryContainer = evt->GetTrajectoryContainer();
00036   G4int n_trajectories = 0;
00037   if (trajectoryContainer) n_trajectories = trajectoryContainer->entries();
00038   
00039   // periodic printing
00040   //
00041     if (event_id%100 == 0) {
00042     G4cout << ">>> Event " << evt->GetEventID() << G4endl;
00043 
00044   }
00045     
00046   // extract the trajectories and draw them
00047   //
00048   if (G4VVisManager::GetConcreteInstance())
00049     {
00050      for (G4int i=0; i<n_trajectories; i++) 
00051         { G4Trajectory* trj = (G4Trajectory*)
00052                                     ((*(evt->GetTrajectoryContainer()))[i]);
00053           trj->DrawTrajectory(1000);
00054         }
00055     }
00056 }


The documentation for this class was generated from the following files:
Generated on Mon Mar 27 12:19:54 2006 for MUSR by  doxygen 1.4.6