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

#include <WLSStackingAction.hh>

Inheritance diagram for WLSStackingAction:
Collaboration diagram for WLSStackingAction:

Public Member Functions

 WLSStackingAction ()
 
virtual ~WLSStackingAction ()
 
virtual G4ClassificationOfNewTrack ClassifyNewTrack (const G4Track *)
 
virtual void NewStage ()
 
virtual void PrepareNewEvent ()
 
- Public Member Functions inherited from G4UserStackingAction
 G4UserStackingAction ()
 
virtual ~G4UserStackingAction ()
 
void SetStackManager (G4StackManager *value)
 

Additional Inherited Members

- Protected Attributes inherited from G4UserStackingAction
G4StackManagerstackManager
 

Detailed Description

Definition at line 41 of file WLSStackingAction.hh.

Constructor & Destructor Documentation

WLSStackingAction::WLSStackingAction ( )

Definition at line 42 of file WLSStackingAction.cc.

42 : fPhotonCounter(0) { }
WLSStackingAction::~WLSStackingAction ( )
virtual

Definition at line 46 of file WLSStackingAction.cc.

46 { }

Member Function Documentation

G4ClassificationOfNewTrack WLSStackingAction::ClassifyNewTrack ( const G4Track aTrack)
virtual

Reimplemented from G4UserStackingAction.

Definition at line 51 of file WLSStackingAction.cc.

52 {
53  G4ParticleDefinition* particleType = aTrack->GetDefinition();
54 
55  // keep primary particle
56  if (aTrack->GetParentID() == 0) return fUrgent;
57 
58  if (particleType == G4OpticalPhoton::OpticalPhotonDefinition()) {
59  // keep optical photon
60  fPhotonCounter++;
61  return fUrgent;
62  } else {
63  // discard all other secondaries
64  // return fKill;
65  }
66  return fUrgent;
67 }
G4ParticleDefinition * GetDefinition() const
G4int GetParentID() const
static G4OpticalPhoton * OpticalPhotonDefinition()

Here is the call graph for this function:

void WLSStackingAction::NewStage ( )
virtual

Reimplemented from G4UserStackingAction.

Definition at line 71 of file WLSStackingAction.cc.

71  {
72  // G4cout << "Number of optical photons produces in this event : "
73  // << fPhotonCounter << G4endl;
74 }
void WLSStackingAction::PrepareNewEvent ( )
virtual

Reimplemented from G4UserStackingAction.

Definition at line 78 of file WLSStackingAction.cc.

78 { fPhotonCounter = 0; }

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