GEMC  2.2
Geant4 Monte-Carlo Framework
MEventAction.h
Go to the documentation of this file.
1 #ifndef MEventAction_H
14 #define MEventAction_H 1
15 
16 // G4 headers
17 #include "G4UserEventAction.hh"
18 
19 // gemc headers
20 #include "outputFactory.h"
21 #include "gbank.h"
22 #include "HitProcess.h"
23 #include "sensitiveDetector.h"
24 #include "options.h"
26 
27 
41 class TInfos
42 {
43  public:
44  TInfos(){;}
45  TInfos(int MTID)
46  {
47  mtid = MTID;
48  mpid = 0;
49  mv = G4ThreeVector(0.,0.,0.);
50  }
51  ~TInfos(){;}
52 
53  public:
54  int mtid; // mother track id
55  int mpid; // mother PID
56 
57  G4ThreeVector mv;
58 };
59 
60 vector<int> vector_mtids( map<int, TInfos> tinfos, vector<int> tids);
61 vector<int> vector_mpids( map<int, TInfos> tinfos, vector<int> tids);
62 vector<G4ThreeVector> vector_mvert( map<int, TInfos> tinfos, vector<int> tids);
63 vector<int> vector_zint( int size);
64 vector<G4ThreeVector> vector_zthre( int size);
65 
66 
78 {
79  public:
80  MEventAction(goptions, map<string, double>);
81  ~MEventAction();
82 
84 
86  map<string, outputFactoryInMap> *outputFactoryMap;
87  map<string, sensitiveDetector*> SeDe_Map;
88  map<string, HitProcess_Factory> *hitProcessMap;
89  map<string, gBank> *banksMap;
90  map<string, double> gPars;
92 
93  map<int, int> hierarchy;
94  map<int, int> momDaugther;
95  vector<int> vector_otids(vector<int> tids);
96 
97 
98  int evtN;
99  string hd_msg;
100  int Modulo;
101  double VERB;
102  string catch_v;
104  int MAXP;
105  string WRITE_ALLRAW;
106  string WRITE_INTRAW;
107  string WRITE_INTDGT;
108  string SIGNALVT;
109 
110  public:
111  void BeginOfEventAction(const G4Event*);
112  void EndOfEventAction(const G4Event*);
113  void SetEvtNumber(int N){evtN = N;}
114 
115 };
116 
117 #endif
118 
119 
120 
121 
int SAVE_ALL_MOTHERS
Loops over the stored trajectories to store mother vertex and pid in the output.
Definition: MEventAction.h:103
void SetEvtNumber(int N)
Sets Event Number.
Definition: MEventAction.h:113
int evtN
Event Number.
Definition: MEventAction.h:98
goptions gemcOpt
gemc options
Definition: MEventAction.h:83
TInfos(int MTID)
Definition: MEventAction.h:45
int mpid
Definition: MEventAction.h:55
map< string, double > gPars
Parameters Map.
Definition: MEventAction.h:90
int Modulo
Print Log Event every Modulo.
Definition: MEventAction.h:100
double VERB
Event Verbosity.
Definition: MEventAction.h:101
MPrimaryGeneratorAction * gen_action
Generator Action.
Definition: MEventAction.h:91
map< string, sensitiveDetector * > SeDe_Map
Sensitive detector Map.
Definition: MEventAction.h:87
vector< int > vector_mtids(map< int, TInfos > tinfos, vector< int > tids)
Definition: MEventAction.cc:52
map< string, gBank > * banksMap
Bank Map.
Definition: MEventAction.h:89
string hd_msg
Event Action Message.
Definition: MEventAction.h:99
int MAXP
Max number of generated particles to save on output stream.
Definition: MEventAction.h:104
G4ThreeVector mv
Definition: MEventAction.h:57
map< int, int > momDaugther
mom - daughter relationship
Definition: MEventAction.h:94
string WRITE_INTDGT
List of detectors for which digitized integrated info need to be NOT saved.
Definition: MEventAction.h:107
vector< G4ThreeVector > vector_mvert(map< int, TInfos > tinfos, vector< int > tids)
Definition: MEventAction.cc:70
map< string, outputFactoryInMap > * outputFactoryMap
outputFactory map
Definition: MEventAction.h:86
map< string, HitProcess_Factory > * hitProcessMap
Hit Process Routine Factory Map.
Definition: MEventAction.h:88
vector< G4ThreeVector > vector_zthre(int size)
provides a vector of (0,0,0)
Definition: MEventAction.cc:43
string catch_v
Print Log for volume.
Definition: MEventAction.h:102
int mtid
Definition: MEventAction.h:54
map< int, int > hierarchy
Hierarchy map.
Definition: MEventAction.h:93
string WRITE_ALLRAW
List of detectors for which geant4 all raw info need to be saved.
Definition: MEventAction.h:105
outputContainer * outContainer
outputContainer class - contains the output format.
Definition: MEventAction.h:85
vector< int > vector_mpids(map< int, TInfos > tinfos, vector< int > tids)
Definition: MEventAction.cc:61
string WRITE_INTRAW
List of detectors for which geant4 raw integrated info need to be saved.
Definition: MEventAction.h:106
vector< int > vector_zint(int size)
provides a vector of 0
Definition: MEventAction.cc:34
string SIGNALVT
List of detectors for which voltage versus time need to be saved.
Definition: MEventAction.h:108