forked from JeffersonLab/SBS-offline
-
Notifications
You must be signed in to change notification settings - Fork 0
/
SBSSimEvent.h
60 lines (41 loc) · 2.12 KB
/
SBSSimEvent.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
#ifndef __SBSSimEvent_h
#define __SBSSimEvent_h
//#include "gmn_dig_tree.h"
//#include "g4sbs_tree.h"
#include "gmn_tree_digitized.h"
#include "genrp_tree_digitized.h"
enum Exp_t { kGEp, kGEnRP, kGMN, kSIDIS};
class TTree;
class SBSSimEvent {
public:
//SBSSimEvent(){}; // Default constructor, for ROOT I/O
//Now we want to initialize the ROOT tree the same way
//SBSSimEvent(TTree* tree, TString experiment="gmn");//, std::vector<TString> det_list);
SBSSimEvent(TTree* tree, Exp_t experiment=kGMN);//, std::vector<TString> det_list);
virtual ~SBSSimEvent(){};
virtual Int_t GetEntry(Long64_t entry);
virtual void Clear( const Option_t* opt="" );
virtual void Print( const Option_t* opt="" ) const;
ULong64_t RunID;
ULong64_t EvtID;
//AJRP: redesign for simplicity/portability/maintainability:
//We probably don't actually need these getter and setter functions, but it doesn't hurt to have them.
//void SetExperiment( TString expname ){ fExperiment = expname; }
//TString GetExperiment() const { return fExperiment; }
//TString fExperiment; //string that tells us which simulated experiment we are doing
void SetExperiment( Exp_t exp ){ fExperiment = exp; }
Exp_t GetExperiment() const { return fExperiment; }
Exp_t fExperiment;
//Auto-generated ROOT Tree classes for each experiment ROOT tree; generated using TTree::MakeClass()
//Later on, any time we want to analyze a g4sbs root file whose format has changed, we can just run TTree::MakeClass on that root file with the appropriate
//class name, and copy the source and header files into SBS-offline,
//recompile, and voila: compatibility guaranteed:
gmn_tree_digitized *Tgmn;
//gep_tree_digitized *Tgep;
genrp_tree_digitized *Tgenrp;//EPAF: for now, genrp tree is thought as a complement of the GMN tree.
// we might keep it this way unless it induces crashes or significant slowdown!
//sidis_tree_digitized *Tsidis;
// gen_tree_digitized *Tgen; //This actually seems like it wouldn't require anything different from gmn.
ClassDef(SBSSimEvent, 1) // Simulated data for one event
};
#endif