flow_pDST.h 16 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355
  1. /*
  2. Needed by StHbtFlowPicoReader. Describes the "empirical" (see the note below)
  3. structure of STAR flow pico DST files. Valid as long as that structure is valid.
  4. */
  5. //////////////////////////////////////////////////////////
  6. // This class has been automatically generated
  7. // (Fri Apr 12 14:53:27 2002 by ROOT version3.02/07)
  8. // from TTree FlowTree/Flow Pico Tree
  9. // found on file: /auto/stardata/starspec2/flow_pDST_production/reco/ProductionMinBias/FullField/P02gc/2001/2269018/st_physics_2269018_raw_0001.flowpicoevent.root
  10. //////////////////////////////////////////////////////////
  11. #ifndef flow_pDST_h
  12. #define flow_pDST_h
  13. #include <TROOT.h>
  14. #include <TChain.h>
  15. #include <TFile.h>
  16. const Int_t kMaxfTracks = 7000;
  17. class flow_pDST {
  18. public :
  19. TTree *fChain; //!pointer to the analyzed TTree or TChain
  20. Int_t fCurrent; //!current Tree number in a TChain
  21. //Declaration of leaves types
  22. UInt_t fUniqueID;
  23. UInt_t fBits;
  24. Int_t mVersion;
  25. Int_t mNtrack;
  26. Int_t mEventID;
  27. Int_t mRunID;
  28. Double_t mMagneticField;
  29. Double_t mCenterOfMassEnergy;
  30. Short_t mBeamMassNumberEast;
  31. Short_t mBeamMassNumberWest;
  32. UInt_t mOrigMult;
  33. UInt_t mL0TriggerWord;
  34. UInt_t mUncorrNegMult;
  35. UInt_t mUncorrPosMult;
  36. UInt_t mMultEta;
  37. UInt_t mCentrality;
  38. Float_t mVertexX;
  39. Float_t mVertexY;
  40. Float_t mVertexZ;
  41. Float_t mCTB;
  42. Float_t mZDCe;
  43. Float_t mZDCw;
  44. Int_t fTracks_;
  45. UInt_t fTracks_fUniqueID[kMaxfTracks]; //[fTracks_]
  46. UInt_t fTracks_fBits[kMaxfTracks]; //[fTracks_]
  47. Float_t fTracks_mPt[kMaxfTracks]; //[fTracks_]
  48. Float_t fTracks_mPtGlobal[kMaxfTracks]; //[fTracks_]
  49. Float_t fTracks_mEta[kMaxfTracks]; //[fTracks_]
  50. Float_t fTracks_mEtaGlobal[kMaxfTracks]; //[fTracks_]
  51. Float_t fTracks_mDedx[kMaxfTracks]; //[fTracks_]
  52. Float_t fTracks_mPhi[kMaxfTracks]; //[fTracks_]
  53. Float_t fTracks_mPhiGlobal[kMaxfTracks]; //[fTracks_]
  54. Short_t fTracks_mCharge[kMaxfTracks]; //[fTracks_]
  55. Float_t fTracks_mDca[kMaxfTracks]; //[fTracks_]
  56. Float_t fTracks_mDcaSigned[kMaxfTracks]; //[fTracks_]
  57. Float_t fTracks_mDcaGlobal[kMaxfTracks]; //[fTracks_]
  58. Float_t fTracks_mChi2[kMaxfTracks]; //[fTracks_]
  59. Int_t fTracks_mFitPts[kMaxfTracks]; //[fTracks_]
  60. Int_t fTracks_mMaxPts[kMaxfTracks]; //[fTracks_]
  61. Int_t fTracks_mNhits[kMaxfTracks]; //[fTracks_]
  62. Int_t fTracks_mNdedxPts[kMaxfTracks]; //[fTracks_]
  63. Float_t fTracks_mTrackLength[kMaxfTracks]; //[fTracks_]
  64. Int_t fTracks_mPidPion[kMaxfTracks]; //[fTracks_]
  65. Int_t fTracks_mPidProton[kMaxfTracks]; //[fTracks_]
  66. Int_t fTracks_mPidKaon[kMaxfTracks]; //[fTracks_]
  67. Int_t fTracks_mPidDeuteron[kMaxfTracks]; //[fTracks_]
  68. Int_t fTracks_mPidElectron[kMaxfTracks]; //[fTracks_]
  69. Int_t fTracks_mMostLikelihoodPID[kMaxfTracks]; //[fTracks_]
  70. Float_t fTracks_mMostLikelihoodProb[kMaxfTracks]; //[fTracks_]
  71. Int_t fTracks_mExtrapTag[kMaxfTracks]; //[fTracks_]
  72. Float_t fTracks_mElectronPositronProb[kMaxfTracks]; //[fTracks_]
  73. Float_t fTracks_mPionPlusMinusProb[kMaxfTracks]; //[fTracks_]
  74. Float_t fTracks_mKaonPlusMinusProb[kMaxfTracks]; //[fTracks_]
  75. Float_t fTracks_mProtonPbarProb[kMaxfTracks]; //[fTracks_]
  76. Float_t fTracks_mDcaGlobalX[kMaxfTracks]; //[fTracks_]
  77. Float_t fTracks_mDcaGlobalY[kMaxfTracks]; //[fTracks_]
  78. Float_t fTracks_mDcaGlobalZ[kMaxfTracks]; //[fTracks_]
  79. UInt_t fTracks_mTopologyMap0[kMaxfTracks]; //[fTracks_]
  80. UInt_t fTracks_mTopologyMap1[kMaxfTracks]; //[fTracks_]
  81. //List of branches
  82. TBranch *b_fUniqueID; //!
  83. TBranch *b_fBits; //!
  84. TBranch *b_mVersion; //!
  85. TBranch *b_mNtrack; //!
  86. TBranch *b_mEventID; //!
  87. TBranch *b_mRunID; //!
  88. TBranch *b_mMagneticField; //!
  89. TBranch *b_mCenterOfMassEnergy; //!
  90. TBranch *b_mBeamMassNumberEast; //!
  91. TBranch *b_mBeamMassNumberWest; //!
  92. TBranch *b_mOrigMult; //!
  93. TBranch *b_mL0TriggerWord; //!
  94. TBranch *b_mUncorrNegMult; //!
  95. TBranch *b_mUncorrPosMult; //!
  96. TBranch *b_mMultEta; //!
  97. TBranch *b_mCentrality; //!
  98. TBranch *b_mVertexX; //!
  99. TBranch *b_mVertexY; //!
  100. TBranch *b_mVertexZ; //!
  101. TBranch *b_mCTB; //!
  102. TBranch *b_mZDCe; //!
  103. TBranch *b_mZDCw; //!
  104. TBranch *b_fTracks_; //!
  105. TBranch *b_fTracks_fUniqueID; //!
  106. TBranch *b_fTracks_fBits; //!
  107. TBranch *b_fTracks_mPt; //!
  108. TBranch *b_fTracks_mPtGlobal; //!
  109. TBranch *b_fTracks_mEta; //!
  110. TBranch *b_fTracks_mEtaGlobal; //!
  111. TBranch *b_fTracks_mDedx; //!
  112. TBranch *b_fTracks_mPhi; //!
  113. TBranch *b_fTracks_mPhiGlobal; //!
  114. TBranch *b_fTracks_mCharge; //!
  115. TBranch *b_fTracks_mDca; //!
  116. TBranch *b_fTracks_mDcaSigned; //!
  117. TBranch *b_fTracks_mDcaGlobal; //!
  118. TBranch *b_fTracks_mChi2; //!
  119. TBranch *b_fTracks_mFitPts; //!
  120. TBranch *b_fTracks_mMaxPts; //!
  121. TBranch *b_fTracks_mNhits; //!
  122. TBranch *b_fTracks_mNdedxPts; //!
  123. TBranch *b_fTracks_mTrackLength; //!
  124. TBranch *b_fTracks_mPidPion; //!
  125. TBranch *b_fTracks_mPidProton; //!
  126. TBranch *b_fTracks_mPidKaon; //!
  127. TBranch *b_fTracks_mPidDeuteron; //!
  128. TBranch *b_fTracks_mPidElectron; //!
  129. TBranch *b_fTracks_mMostLikelihoodPID; //!
  130. TBranch *b_fTracks_mMostLikelihoodProb; //!
  131. TBranch *b_fTracks_mExtrapTag; //!
  132. TBranch *b_fTracks_mElectronPositronProb; //!
  133. TBranch *b_fTracks_mPionPlusMinusProb; //!
  134. TBranch *b_fTracks_mKaonPlusMinusProb; //!
  135. TBranch *b_fTracks_mProtonPbarProb; //!
  136. TBranch *b_fTracks_mDcaGlobalX; //!
  137. TBranch *b_fTracks_mDcaGlobalY; //!
  138. TBranch *b_fTracks_mDcaGlobalZ; //!
  139. TBranch *b_fTracks_mTopologyMap0; //!
  140. TBranch *b_fTracks_mTopologyMap1; //!
  141. flow_pDST(TTree *tree=0);
  142. ~flow_pDST();
  143. Int_t Cut(Int_t entry);
  144. Int_t GetEntry(Int_t entry);
  145. Int_t LoadTree(Int_t entry);
  146. void Init(TTree *tree);
  147. void Loop();
  148. Bool_t Notify();
  149. void Show(Int_t entry = -1);
  150. };
  151. #endif
  152. #ifdef flow_pDST_cxx
  153. flow_pDST::flow_pDST(TTree *tree)
  154. {
  155. // if parameter tree is not specified (or zero), connect the file
  156. // used to generate this class and read the Tree.
  157. if (tree == 0) {
  158. TFile *f = (TFile*)gROOT->GetListOfFiles()->FindObject("/auto/stardata/starspec2/flow_pDST_production/reco/ProductionMinBias/FullField/P02gc/2001/2269018/st_physics_2269018_raw_0001.flowpicoevent.root");
  159. if (!f) {
  160. f = new TFile("/auto/stardata/starspec2/flow_pDST_production/reco/ProductionMinBias/FullField/P02gc/2001/2269018/st_physics_2269018_raw_0001.flowpicoevent.root");
  161. }
  162. tree = (TTree*)gDirectory->Get("FlowTree");
  163. }
  164. Init(tree);
  165. }
  166. flow_pDST::~flow_pDST()
  167. {
  168. if (!fChain) return;
  169. delete fChain->GetCurrentFile();
  170. }
  171. Int_t flow_pDST::GetEntry(Int_t entry)
  172. {
  173. // Read contents of entry.
  174. if (!fChain) return 0;
  175. return fChain->GetEntry(entry);
  176. }
  177. Int_t flow_pDST::LoadTree(Int_t entry)
  178. {
  179. // Set the environment to read one entry
  180. if (!fChain) return -5;
  181. Int_t centry = fChain->LoadTree(entry);
  182. if (centry < 0) return centry;
  183. if (fChain->IsA() != TChain::Class()) return centry;
  184. TChain *chain = (TChain*)fChain;
  185. if (chain->GetTreeNumber() != fCurrent) {
  186. fCurrent = chain->GetTreeNumber();
  187. Notify();
  188. }
  189. return centry;
  190. }
  191. void flow_pDST::Init(TTree *tree)
  192. {
  193. // Set branch addresses
  194. if (tree == 0) return;
  195. fChain = tree;
  196. fCurrent = -1;
  197. fChain->SetMakeClass(1);
  198. fChain->SetBranchAddress("fUniqueID",&fUniqueID);
  199. fChain->SetBranchAddress("fBits",&fBits);
  200. fChain->SetBranchAddress("mVersion",&mVersion);
  201. fChain->SetBranchAddress("mNtrack",&mNtrack);
  202. fChain->SetBranchAddress("mEventID",&mEventID);
  203. fChain->SetBranchAddress("mRunID",&mRunID);
  204. fChain->SetBranchAddress("mMagneticField",&mMagneticField);
  205. fChain->SetBranchAddress("mCenterOfMassEnergy",&mCenterOfMassEnergy);
  206. fChain->SetBranchAddress("mBeamMassNumberEast",&mBeamMassNumberEast);
  207. fChain->SetBranchAddress("mBeamMassNumberWest",&mBeamMassNumberWest);
  208. fChain->SetBranchAddress("mOrigMult",&mOrigMult);
  209. fChain->SetBranchAddress("mL0TriggerWord",&mL0TriggerWord);
  210. fChain->SetBranchAddress("mUncorrNegMult",&mUncorrNegMult);
  211. fChain->SetBranchAddress("mUncorrPosMult",&mUncorrPosMult);
  212. fChain->SetBranchAddress("mMultEta",&mMultEta);
  213. fChain->SetBranchAddress("mCentrality",&mCentrality);
  214. fChain->SetBranchAddress("mVertexX",&mVertexX);
  215. fChain->SetBranchAddress("mVertexY",&mVertexY);
  216. fChain->SetBranchAddress("mVertexZ",&mVertexZ);
  217. fChain->SetBranchAddress("mCTB",&mCTB);
  218. fChain->SetBranchAddress("mZDCe",&mZDCe);
  219. fChain->SetBranchAddress("mZDCw",&mZDCw);
  220. fChain->SetBranchAddress("fTracks",&fTracks_);
  221. fChain->SetBranchAddress("fTracks.fUniqueID",fTracks_fUniqueID);
  222. fChain->SetBranchAddress("fTracks.fBits",fTracks_fBits);
  223. fChain->SetBranchAddress("fTracks.mPt",fTracks_mPt);
  224. fChain->SetBranchAddress("fTracks.mPtGlobal",fTracks_mPtGlobal);
  225. fChain->SetBranchAddress("fTracks.mEta",fTracks_mEta);
  226. fChain->SetBranchAddress("fTracks.mEtaGlobal",fTracks_mEtaGlobal);
  227. fChain->SetBranchAddress("fTracks.mDedx",fTracks_mDedx);
  228. fChain->SetBranchAddress("fTracks.mPhi",fTracks_mPhi);
  229. fChain->SetBranchAddress("fTracks.mPhiGlobal",fTracks_mPhiGlobal);
  230. fChain->SetBranchAddress("fTracks.mCharge",fTracks_mCharge);
  231. fChain->SetBranchAddress("fTracks.mDca",fTracks_mDca);
  232. fChain->SetBranchAddress("fTracks.mDcaSigned",fTracks_mDcaSigned);
  233. fChain->SetBranchAddress("fTracks.mDcaGlobal",fTracks_mDcaGlobal);
  234. fChain->SetBranchAddress("fTracks.mChi2",fTracks_mChi2);
  235. fChain->SetBranchAddress("fTracks.mFitPts",fTracks_mFitPts);
  236. fChain->SetBranchAddress("fTracks.mMaxPts",fTracks_mMaxPts);
  237. fChain->SetBranchAddress("fTracks.mNhits",fTracks_mNhits);
  238. fChain->SetBranchAddress("fTracks.mNdedxPts",fTracks_mNdedxPts);
  239. fChain->SetBranchAddress("fTracks.mTrackLength",fTracks_mTrackLength);
  240. fChain->SetBranchAddress("fTracks.mPidPion",fTracks_mPidPion);
  241. fChain->SetBranchAddress("fTracks.mPidProton",fTracks_mPidProton);
  242. fChain->SetBranchAddress("fTracks.mPidKaon",fTracks_mPidKaon);
  243. fChain->SetBranchAddress("fTracks.mPidDeuteron",fTracks_mPidDeuteron);
  244. fChain->SetBranchAddress("fTracks.mPidElectron",fTracks_mPidElectron);
  245. fChain->SetBranchAddress("fTracks.mMostLikelihoodPID",fTracks_mMostLikelihoodPID);
  246. fChain->SetBranchAddress("fTracks.mMostLikelihoodProb",fTracks_mMostLikelihoodProb);
  247. fChain->SetBranchAddress("fTracks.mExtrapTag",fTracks_mExtrapTag);
  248. fChain->SetBranchAddress("fTracks.mElectronPositronProb",fTracks_mElectronPositronProb);
  249. fChain->SetBranchAddress("fTracks.mPionPlusMinusProb",fTracks_mPionPlusMinusProb);
  250. fChain->SetBranchAddress("fTracks.mKaonPlusMinusProb",fTracks_mKaonPlusMinusProb);
  251. fChain->SetBranchAddress("fTracks.mProtonPbarProb",fTracks_mProtonPbarProb);
  252. fChain->SetBranchAddress("fTracks.mDcaGlobalX",fTracks_mDcaGlobalX);
  253. fChain->SetBranchAddress("fTracks.mDcaGlobalY",fTracks_mDcaGlobalY);
  254. fChain->SetBranchAddress("fTracks.mDcaGlobalZ",fTracks_mDcaGlobalZ);
  255. fChain->SetBranchAddress("fTracks.mTopologyMap0",fTracks_mTopologyMap0);
  256. fChain->SetBranchAddress("fTracks.mTopologyMap1",fTracks_mTopologyMap1);
  257. Notify();
  258. }
  259. Bool_t flow_pDST::Notify()
  260. {
  261. // Called when loading a new file.
  262. // Get branch pointers.
  263. b_fUniqueID = fChain->GetBranch("fUniqueID");
  264. b_fBits = fChain->GetBranch("fBits");
  265. b_mVersion = fChain->GetBranch("mVersion");
  266. b_mNtrack = fChain->GetBranch("mNtrack");
  267. b_mEventID = fChain->GetBranch("mEventID");
  268. b_mRunID = fChain->GetBranch("mRunID");
  269. b_mMagneticField = fChain->GetBranch("mMagneticField");
  270. b_mCenterOfMassEnergy = fChain->GetBranch("mCenterOfMassEnergy");
  271. b_mBeamMassNumberEast = fChain->GetBranch("mBeamMassNumberEast");
  272. b_mBeamMassNumberWest = fChain->GetBranch("mBeamMassNumberWest");
  273. b_mOrigMult = fChain->GetBranch("mOrigMult");
  274. b_mL0TriggerWord = fChain->GetBranch("mL0TriggerWord");
  275. b_mUncorrNegMult = fChain->GetBranch("mUncorrNegMult");
  276. b_mUncorrPosMult = fChain->GetBranch("mUncorrPosMult");
  277. b_mMultEta = fChain->GetBranch("mMultEta");
  278. b_mCentrality = fChain->GetBranch("mCentrality");
  279. b_mVertexX = fChain->GetBranch("mVertexX");
  280. b_mVertexY = fChain->GetBranch("mVertexY");
  281. b_mVertexZ = fChain->GetBranch("mVertexZ");
  282. b_mCTB = fChain->GetBranch("mCTB");
  283. b_mZDCe = fChain->GetBranch("mZDCe");
  284. b_mZDCw = fChain->GetBranch("mZDCw");
  285. b_fTracks_ = fChain->GetBranch("fTracks");
  286. b_fTracks_fUniqueID = fChain->GetBranch("fTracks.fUniqueID");
  287. b_fTracks_fBits = fChain->GetBranch("fTracks.fBits");
  288. b_fTracks_mPt = fChain->GetBranch("fTracks.mPt");
  289. b_fTracks_mPtGlobal = fChain->GetBranch("fTracks.mPtGlobal");
  290. b_fTracks_mEta = fChain->GetBranch("fTracks.mEta");
  291. b_fTracks_mEtaGlobal = fChain->GetBranch("fTracks.mEtaGlobal");
  292. b_fTracks_mDedx = fChain->GetBranch("fTracks.mDedx");
  293. b_fTracks_mPhi = fChain->GetBranch("fTracks.mPhi");
  294. b_fTracks_mPhiGlobal = fChain->GetBranch("fTracks.mPhiGlobal");
  295. b_fTracks_mCharge = fChain->GetBranch("fTracks.mCharge");
  296. b_fTracks_mDca = fChain->GetBranch("fTracks.mDca");
  297. b_fTracks_mDcaSigned = fChain->GetBranch("fTracks.mDcaSigned");
  298. b_fTracks_mDcaGlobal = fChain->GetBranch("fTracks.mDcaGlobal");
  299. b_fTracks_mChi2 = fChain->GetBranch("fTracks.mChi2");
  300. b_fTracks_mFitPts = fChain->GetBranch("fTracks.mFitPts");
  301. b_fTracks_mMaxPts = fChain->GetBranch("fTracks.mMaxPts");
  302. b_fTracks_mNhits = fChain->GetBranch("fTracks.mNhits");
  303. b_fTracks_mNdedxPts = fChain->GetBranch("fTracks.mNdedxPts");
  304. b_fTracks_mTrackLength = fChain->GetBranch("fTracks.mTrackLength");
  305. b_fTracks_mPidPion = fChain->GetBranch("fTracks.mPidPion");
  306. b_fTracks_mPidProton = fChain->GetBranch("fTracks.mPidProton");
  307. b_fTracks_mPidKaon = fChain->GetBranch("fTracks.mPidKaon");
  308. b_fTracks_mPidDeuteron = fChain->GetBranch("fTracks.mPidDeuteron");
  309. b_fTracks_mPidElectron = fChain->GetBranch("fTracks.mPidElectron");
  310. b_fTracks_mMostLikelihoodPID = fChain->GetBranch("fTracks.mMostLikelihoodPID");
  311. b_fTracks_mMostLikelihoodProb = fChain->GetBranch("fTracks.mMostLikelihoodProb");
  312. b_fTracks_mExtrapTag = fChain->GetBranch("fTracks.mExtrapTag");
  313. b_fTracks_mElectronPositronProb = fChain->GetBranch("fTracks.mElectronPositronProb");
  314. b_fTracks_mPionPlusMinusProb = fChain->GetBranch("fTracks.mPionPlusMinusProb");
  315. b_fTracks_mKaonPlusMinusProb = fChain->GetBranch("fTracks.mKaonPlusMinusProb");
  316. b_fTracks_mProtonPbarProb = fChain->GetBranch("fTracks.mProtonPbarProb");
  317. b_fTracks_mDcaGlobalX = fChain->GetBranch("fTracks.mDcaGlobalX");
  318. b_fTracks_mDcaGlobalY = fChain->GetBranch("fTracks.mDcaGlobalY");
  319. b_fTracks_mDcaGlobalZ = fChain->GetBranch("fTracks.mDcaGlobalZ");
  320. b_fTracks_mTopologyMap0 = fChain->GetBranch("fTracks.mTopologyMap0");
  321. b_fTracks_mTopologyMap1 = fChain->GetBranch("fTracks.mTopologyMap1");
  322. return kTRUE;
  323. }
  324. void flow_pDST::Show(Int_t entry)
  325. {
  326. // Print contents of entry.
  327. // If entry is not specified, print current entry
  328. if (!fChain) return;
  329. fChain->Show(entry);
  330. }
  331. Int_t flow_pDST::Cut(Int_t entry)
  332. {
  333. // This function may be called from Loop.
  334. // returns 1 if entry is accepted.
  335. // returns -1 otherwise.
  336. return 1;
  337. }
  338. #endif // #ifdef flow_pDST_cxx