]> git.uio.no Git - u/mrichter/AliRoot.git/blob - AliGeant4/AliStackingAction.h
Initial version
[u/mrichter/AliRoot.git] / AliGeant4 / AliStackingAction.h
1 // $Id$
2 // Category: event
3 //
4 // Class that defines Alice stacking mechanism.
5
6 #ifndef ALI_STACKING_ACTION_H
7 #define ALI_STACKING_ACTION_H
8
9 #include <G4UserStackingAction.hh>
10 #include <G4TrackStack.hh>
11
12 #include <globals.hh>
13
14 class AliStackingActionMessenger;
15 class AliTrackingAction;
16 class G4Track;
17
18 class AliStackingAction : public G4UserStackingAction
19 {
20   public:
21     AliStackingAction();
22     // --> protected
23     // AliStackingAction(const AliStackingAction& right);
24     virtual ~AliStackingAction();
25
26     // methods
27     G4ClassificationOfNewTrack ClassifyNewTrack(const G4Track* track);
28     void NewStage();
29     void ClearPrimaryStack();
30     void PrepareNewEvent();
31
32     // set methods
33     void SetVerboseLevel(G4int level);
34
35     // get methods
36     G4int GetVerboseLevel() const;
37
38   protected:
39     AliStackingAction(const AliStackingAction& right);
40
41     // operators
42     AliStackingAction& operator=(const AliStackingAction& right);
43
44   private:
45     // data members
46     G4int                        fStage;          //stage number
47     G4int                        fVerboseLevel;   //verbose level
48     G4bool                       fSavePrimaries;  //control of saving primaries
49     G4TrackStack*                fPrimaryStack;   //stack of primary tracks
50     AliTrackingAction*           fTrackingAction; //AliTrackingAction
51     AliStackingActionMessenger*  fMessenger;      //messenger
52 };
53
54
55 // inline methods
56
57 inline void AliStackingAction::SetVerboseLevel(G4int level)
58 { fVerboseLevel = level; }
59
60 inline G4int AliStackingAction::GetVerboseLevel() const
61 { return fVerboseLevel; }
62
63 #endif //ALI_STACKING_ACTION_H
64