Geant4  10.03.p03
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
RE05SteppingAction Class Reference

#include <RE05SteppingAction.hh>

Inheritance diagram for RE05SteppingAction:
Collaboration diagram for RE05SteppingAction:

Public Member Functions

 RE05SteppingAction ()
 
virtual ~RE05SteppingAction ()
 
virtual void UserSteppingAction (const G4Step *)
 
- Public Member Functions inherited from G4UserSteppingAction
 G4UserSteppingAction ()
 
virtual ~G4UserSteppingAction ()
 
virtual void SetSteppingManagerPointer (G4SteppingManager *pValue)
 

Additional Inherited Members

- Protected Attributes inherited from G4UserSteppingAction
G4SteppingManagerfpSteppingManager
 

Detailed Description

Definition at line 38 of file RE05SteppingAction.hh.

Constructor & Destructor Documentation

RE05SteppingAction::RE05SteppingAction ( )

Definition at line 44 of file RE05SteppingAction.cc.

RE05SteppingAction::~RE05SteppingAction ( )
virtual

Definition at line 50 of file RE05SteppingAction.cc.

51 {}

Member Function Documentation

void RE05SteppingAction::UserSteppingAction ( const G4Step theStep)
virtual

Reimplemented from G4UserSteppingAction.

Definition at line 55 of file RE05SteppingAction.cc.

56 {
57  G4Track * theTrack = theStep->GetTrack();
58 
59  // check if it is alive
60  if(theTrack->GetTrackStatus()!=fAlive) { return; }
61 
62  // check if it is primary
63  if(theTrack->GetParentID()!=0) { return; }
64 
65  // check if it is NOT muon
66  G4ParticleDefinition * particleType = theTrack->GetDefinition();
67  if((particleType==G4MuonPlus::MuonPlusDefinition())
68  ||(particleType==G4MuonMinus::MuonMinusDefinition()))
69  { return; }
70 
71  // check if it is entering to the calorimeter volume
72  G4StepPoint * thePrePoint = theStep->GetPreStepPoint();
73  G4VPhysicalVolume * thePrePV = thePrePoint->GetPhysicalVolume();
74  G4String thePrePVname = thePrePV->GetName();
75  if(thePrePVname(0,4)=="calo") { return; }
76  G4StepPoint * thePostPoint = theStep->GetPostStepPoint();
77  G4VPhysicalVolume * thePostPV = thePostPoint->GetPhysicalVolume();
78  G4String thePostPVname = thePostPV->GetName();
79  if(thePostPVname(0,4)!="calo") { return; }
80 
81  // then suspend the track
82  theTrack->SetTrackStatus(fSuspend);
83 }
void SetTrackStatus(const G4TrackStatus aTrackStatus)
G4ParticleDefinition * GetDefinition() const
G4int GetParentID() const
static G4MuonPlus * MuonPlusDefinition()
Definition: G4MuonPlus.cc:94
G4TrackStatus GetTrackStatus() const
G4StepPoint * GetPreStepPoint() const
G4VPhysicalVolume * GetPhysicalVolume() const
const G4String & GetName() const
G4StepPoint * GetPostStepPoint() const
static G4MuonMinus * MuonMinusDefinition()
Definition: G4MuonMinus.cc:95
G4Track * GetTrack() const

Here is the call graph for this function:


The documentation for this class was generated from the following files: