StRoot  1
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
StUEMaker2009.h
1 // -*- mode:c++ -*-
2 //
3 // Grant Webb <gdwebb@bnl.edu>
4 // Brookhaven National Laboratory
5 // 30 July 2015
6 //
7 
8 #ifndef ST_UE_MAKER_2009_H
9 #define ST_UE_MAKER_2009_H
10 
11 class TTree;
12 class StJetCandidate;
13 //class StUECandidate;
14 class StJetEvent;
15 class StUeEvent;
16 class StJetSkimEvent;
17 class StPythiaEvent;
18 class StJetVertex;
19 class StJetMaker2009;
20 class StJetSkimEvent;
21 #include <vector>
22 #include "StMaker.h"
23 #include "StSpinPool/StJetEvent/StUeEvent.h"
24 class StUEMaker2009 : public StMaker {
25 
26 public:
27  StUEMaker2009(const char* name = "StUEMaker2009")
28  : StMaker(name)
29  , mFile(0)
30  , mTree(0)
31  {
32  }
33 
34  void Clear(Option_t* option = "");
35  int Init();
36  int Make();
37  int Finish();
38 
39  // Setters
40  void addBranch(const char* name, StAnaPars* anapars, const char* jetname);// StRegionPars* regionPars);
41  void setUeFile(const char* filename);
42 
43  // Getters
44  TTree* tree();
45  StUeEvent* event(const char* branchname);
46 
47 StJetMaker2009 *mJetMaker;
48 StJetSkimEventMaker *mSkimMaker;
49 
50  struct StUeBranch {
51  StUeBranch(const char* name, StAnaPars* anapars, const char* jetname)//, StUEAnaPars* ueanapars, StUEPars* uepars)
52  : name(name)
53  , anapars(anapars)
54  , jetname(jetname)
55  // , jetfinder(jetpars->constructJetFinder())
56  , event(new StUeEvent)
57  {
58  }
59 
60  TString name;
61  StAnaPars* anapars;
62  TString jetname;
63  // StJetPars* jetpars;
64  // StJetFinder* jetfinder;
65  StUeEvent* event;
66  };
67 
68 private:
69  StJetCandidate* findLeadingJet(StJetVertex *vertex);
70  // void AddRegion(StJetCandidate *leadingjet, StjTrackList trackList, StUeEvent *event);
71  // void addJet(const StProtoJet& protojet, StJetEvent* event, StJetVertex* vertex);
72  void copyVertex(const StjPrimaryVertex& vertex, StJetVertex* jetvertex);
73 
74  void copyTrack(const StjTrack&, StJetTrack*);
75  void copyTower(const StjTowerEnergy&, StJetTower*);
76  void copyParticle(const StjMCParticle&, StJetParticle*);
77  void addTracks(const StjTrackList&, StUeEvent*);
78  void addTowers(const StjTowerEnergyList&, StUeEvent*);
79  void addParticles(const StjMCParticleList&, StUeEvent*);
80  vector<StUeBranch*> mUeBranches;
81  TString mFileName;
82  TFile* mFile;
83  TTree* mTree;
84 
85  ClassDef(StUEMaker2009,2);
86 };
87 
88 #endif
void Clear(Option_t *option="")
User defined functions.
StMaker(const char *name="", const char *dummy=0)
Constructor &amp; Destructor.
Definition: StMaker.cxx:188