4 // Author: I.Hrivnacova
6 // Class TG4SteppingAction
7 // -----------------------
8 // This class ensures additional call to sensitive detector
9 // when track crosses a geometrical boundary.
10 // It also enables to define a maximum number of steps
11 // and takes care of stopping of a track when this number
14 #ifndef TG4_STEPPING_ACTION_H
15 #define TG4_STEPPING_ACTION_H
17 #include <G4UserSteppingAction.hh>
24 class TG4SteppingAction : public G4UserSteppingAction
34 // TG4SteppingAction(const TG4SteppingAction& right);
35 virtual ~TG4SteppingAction();
38 virtual void SteppingAction(const G4Step* step) {;}
39 // the following method should not
40 // be overwritten in a derived class
41 virtual void UserSteppingAction(const G4Step* step);
44 void SetLoopVerboseLevel(G4int level);
45 void SetMaxNofSteps(G4int number);
48 G4int GetLoopVerboseLevel() const;
49 G4int GetMaxNofSteps() const;
52 TG4SteppingAction(const TG4SteppingAction& right);
55 TG4SteppingAction& operator=(const TG4SteppingAction& right);
58 void PrintTrackInfo(const G4Track* track) const;
61 G4int fMaxNofSteps; //max number of steps allowed
62 G4int fStandardVerboseLevel; //standard tracking verbose level
63 G4int fLoopVerboseLevel; //tracking verbose level //for looping particles
64 //for looping particles
65 G4int fLoopStepCounter; //loop steps counter
70 inline void TG4SteppingAction::SetLoopVerboseLevel(G4int level)
71 { fLoopVerboseLevel = level; }
73 inline void TG4SteppingAction::SetMaxNofSteps(G4int number)
74 { fMaxNofSteps = number; }
76 inline G4int TG4SteppingAction::GetMaxNofSteps() const
77 { return fMaxNofSteps; }
79 inline G4int TG4SteppingAction::GetLoopVerboseLevel() const
80 { return fLoopVerboseLevel; }
82 #endif //TG4_STEPPING_ACTION_H