KaliVeda
Toolkit for HIC analysis
Loading...
Searching...
No Matches
KVSimFile.cpp
1//Created by KVClassFactory on Tue Jul 17 09:05:17 2012
2//Author: John Frankland,,,
3
4#include "KVSimFile.h"
5#include "KVSimDir.h"
6#include <iostream>
7
9
10using namespace std;
11
12
15
17{
18 // Default constructor
21}
22
23
24
27
28KVSimFile::KVSimFile(KVSimDir* parent, const Char_t* filename, const Char_t* treeinfo, Long64_t treeEntries, const Char_t* treename, const Char_t* branchname)
29 : KVBase(filename, treeinfo), fSimDir(parent), fFiltered(kFALSE), fEvents(treeEntries), fTreeName(treename), fBranchName(branchname)
30{
31 // Default constructor for simulated events file
34}
35
36
37
40
41KVSimFile::KVSimFile(KVSimDir* parent, const Char_t* filename, const Char_t* treeinfo, Long64_t treeEntries, const Char_t* treename, const Char_t* branchname,
42 const Char_t* dataset, const Char_t* system, Int_t run_number, const Char_t* geo_type, const Char_t* orig_file, const Char_t* filt_type)
43 : KVBase(filename, treeinfo), fSimDir(parent), fFiltered(kTRUE), fEvents(treeEntries), fDataSet(dataset), fSystem(system),
44 fRunNumber(run_number), fGeoType(geo_type), fTreeName(treename), fBranchName(branchname), fOrigFile(orig_file), fFiltType(filt_type)
45{
46 // Default constructor for filtered (reconstructed) simulated events file
49}
50
51
52
59
61{
62 // Copy constructor
63 // This ctor is used to make a copy of an existing object (for example
64 // when a method returns an object), and it is always a good idea to
65 // implement it.
66 // If your class allocates memory in its constructor(s) then it is ESSENTIAL :-)
67
68 obj.Copy(*this);
69}
70
71
72
75
77{
78 // Destructor
79}
80
81
82
83
91
92void KVSimFile::Copy(TObject& obj) const
93{
94 // This method copies the current state of 'this' object into 'obj'
95 // You should add here any member variables, for example:
96 // (supposing a member variable KVSimFile::fToto)
97 // CastedObj.fToto = fToto;
98 // or
99 // CastedObj.SetToto( GetToto() );
100
101 KVBase::Copy(obj);
102 KVSimFile& CastedObj = (KVSimFile&)obj;
103 CastedObj.fSimDir = fSimDir;
104 CastedObj.fFiltered = fFiltered;
105 CastedObj.fEvents = fEvents;
106 CastedObj.fDataSet = fDataSet;
107 CastedObj.fSystem = fSystem;
108 CastedObj.fRunNumber = fRunNumber;
109 CastedObj.fGeoType = fGeoType;
110 CastedObj.fTreeName = fTreeName;
111 CastedObj.fBranchName = fBranchName;
112 CastedObj.fOrigFile = fOrigFile;
113 CastedObj.fFiltType = fFiltType;
114 CastedObj.fGemini = fGemini;
116}
117
118
119
121
123{
125 if (!fFiltered) cout << "SIMULATED EVENTS FILE : " << GetName() << endl;
126 else cout << "FILTERED EVENTS FILE : " << GetName() << endl;
127 cout << "--treename: " << GetTreeName() << endl;
128 cout << "--branchname: " << GetBranchName() << endl;
129 cout << "--infos: " << GetTitle() << endl;
130 cout << "--events: " << fEvents << endl;
131 if (fFiltered) {
132 cout << "--Filtering conditions:" << endl;
133 cout << "----dataset:" << fDataSet << endl;
134 cout << "----system:" << fSystem << endl;
135 cout << "----run:" << fRunNumber << endl;
136 cout << "----geometry:" << fGeoType << endl;
137 cout << "----filter:" << fFiltType << endl;
138 cout << "----gemini:";
139 if (fGemini) cout << " " << fGemDecayPerEvent << " decays per event";
140 else cout << " no";
141 cout << endl;
142 }
143}
144
145
int Int_t
char Char_t
constexpr Bool_t kFALSE
constexpr Bool_t kTRUE
const char Option_t
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t WindowAttributes_t Float_t Float_t Float_t Int_t Int_t UInt_t UInt_t Rectangle_t Int_t Int_t Window_t TString Int_t GCValues_t GetPrimarySelectionOwner GetDisplay GetScreen GetColormap GetNativeEvent const char const char dpyName wid window const char font_name cursor keysym reg const char only_if_exist regb h Point_t winding char text const char depth char const char Int_t count const char ColorStruct_t color const char filename
Base class for KaliVeda framework.
Definition KVBase.h:142
virtual void Copy(TObject &) const
Make a copy of this object.
Definition KVBase.cpp:394
Handle directory containing simulated and/or filtered simulated data ,.
Definition KVSimDir.h:44
Handle file containing simulated and/or filtered simulated data ,.
Definition KVSimFile.h:19
const Char_t * GetTreeName() const
Definition KVSimFile.h:113
Int_t fRunNumber
Definition KVSimFile.h:26
Bool_t fGemini
true if statistical decay calculated with Gemini++ before filter
Definition KVSimFile.h:32
TString fSystem
name of system used to filter events
Definition KVSimFile.h:25
Int_t fGemDecayPerEvent
number of Gemini decays performed per primary event
Definition KVSimFile.h:33
TString fDataSet
name of dataset used to filter events
Definition KVSimFile.h:24
TString fOrigFile
name of simulated events file filtered to generate this file
Definition KVSimFile.h:30
void Copy(TObject &) const
Definition KVSimFile.cpp:92
TString fGeoType
type of geometry used for filtering
Definition KVSimFile.h:27
Bool_t fFiltered
=kTRUE for filtered (reconstructed) simulated events
Definition KVSimFile.h:22
void ls(Option_t *opt="") const
TString fFiltType
type of filtering used (Geo, Geo+Thresh, or Full)
Definition KVSimFile.h:31
virtual ~KVSimFile()
Destructor.
Definition KVSimFile.cpp:76
Long64_t fEvents
=number of events in TTree
Definition KVSimFile.h:23
KVSimDir * fSimDir
parent directory
Definition KVSimFile.h:21
TString fTreeName
name of TTree
Definition KVSimFile.h:28
const Char_t * GetBranchName() const
Definition KVSimFile.h:118
TString fBranchName
name of branch containing events
Definition KVSimFile.h:29
KVSimFile()
Default constructor.
Definition KVSimFile.cpp:16
const char * GetName() const override
const char * GetTitle() const override
static void IndentLevel()
long long Long64_t
ClassImp(TPyArg)