StRoot  1
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
StjTrigger2005MCMaker.C
1 #include "StMaker.h"
2 
3 #include "StjTrgPassCondition.h"
4 
5 #include "StjTrgMuDst.h"
6 
7 #include "StjTrgJPWriter.h"
8 #include "StjTrgHTWriter.h"
9 #include "StjTrgMBWriter.h"
10 #include "StjTrgBEMCJetPatchTowerIdMap2005.h"
11 
12 #include "StjTrgMuDst.h"
13 
14 #include "StjTrgSoftMuDstEmcTriggerMakerFactory.h"
15 #include "StjTrgSoftMuDstTriggerSimuMakerFactory.h"
16 
18 
19 public:
20 
21  StjTrigger2005MCMaker(const Char_t *name, TDirectory* file, StMuDstMaker* uDstMaker, StEmcTriggerMaker* emcTrigMaker)
22  : StMaker(name), _file(file), _uDstMaker(uDstMaker)
23  , _softTrgFactory(new StjTrgSoftMuDstEmcTriggerMakerFactory(emcTrigMaker, uDstMaker, new StjTrgBEMCJetPatchTowerIdMap2005()))
24  { }
25 
26  StjTrigger2005MCMaker(const Char_t *name, TDirectory* file, StMuDstMaker* uDstMaker, StTriggerSimuMaker* simuTrig)
27  : StMaker(name), _file(file), _uDstMaker(uDstMaker)
28  , _softTrgFactory(new StjTrgSoftMuDstTriggerSimuMakerFactory(simuTrig, uDstMaker, new StjTrgBEMCJetPatchTowerIdMap2005()))
29  { }
30 
31  virtual ~StjTrigger2005MCMaker() { }
32 
33  const char* GetCVS() const
34  {static const char cvs[]="Tag $Name: $ $Id: StjTrigger2005MCMaker.C,v 1.9 2014/08/06 11:43:24 jeromel Exp $ built " __DATE__ " " __TIME__; return cvs;}
35 
36 private:
37 
38  TDirectory* _file;
39 
40  StMuDstMaker* _uDstMaker;
41  StjTrgSoftFactory* _softTrgFactory;
42 
43  StjTrgWriter* _minbWriter;
44  StjTrgWriter* _bht1Writer;
45  StjTrgWriter* _bht2Writer;
46  StjTrgWriter* _bjp1Writer;
47  StjTrgWriter* _bjp2Writer;
48 
49 public:
50 
51  Int_t Init()
52  {
53  StjTrgPassCondition* minbPassCondition = new StjTrgPassConditionSoftOnly;
54  StjTrg* minbTrg = new StjTrgMuDst(96011, minbPassCondition, _uDstMaker, _softTrgFactory->create());
55  StjTrgPassCondition* minbFillCondition = new StjTrgPassConditionSoftOnly;
56  _minbWriter = new StjTrgMBWriter("trgMINB", "trgMINB", _file, minbTrg, minbFillCondition);
57 
58  StjTrgPassCondition* bht1PassCondition = new StjTrgPassConditionSoftOnly;
59  StjTrg* bht1Trg = new StjTrgMuDst(96201, bht1PassCondition, _uDstMaker, _softTrgFactory->create());
60  StjTrgPassCondition* bht1FillCondition = new StjTrgPassConditionSoftOnly;
61  _bht1Writer = new StjTrgHTWriter("trgBHT1", "trgBHT1", _file, bht1Trg, bht1FillCondition);
62 
63  StjTrgPassCondition* bht2PassCondition = new StjTrgPassConditionSoftOnly;
64  StjTrg* bht2Trg = new StjTrgMuDst(96211, bht2PassCondition, _uDstMaker, _softTrgFactory->create());
65  StjTrgPassCondition* bht2FillCondition = new StjTrgPassConditionSoftOnly;
66  _bht2Writer = new StjTrgHTWriter("trgBHT2", "trgBHT2", _file, bht2Trg, bht2FillCondition);
67 
68  StjTrgPassCondition* bjp1PassCondition = new StjTrgPassConditionSoftOnly;
69  StjTrg* bjp1Trg = new StjTrgMuDst(96221, bjp1PassCondition, _uDstMaker, _softTrgFactory->create());
70  StjTrgPassCondition* bjp1FillCondition = new StjTrgPassConditionSoftOnly;
71  _bjp1Writer = new StjTrgJPWriter("trgBJP1", "trgBJP1", _file, bjp1Trg, bjp1FillCondition);
72 
73  StjTrgPassCondition* bjp2PassCondition = new StjTrgPassConditionSoftOnly;
74  StjTrg* bjp2Trg = new StjTrgMuDst(96233, bjp2PassCondition, _uDstMaker, _softTrgFactory->create());
75  StjTrgPassCondition* bjp2FillCondition = new StjTrgPassConditionSoftOnly;
76  _bjp2Writer = new StjTrgJPWriter("trgBJP2", "trgBJP2", _file, bjp2Trg, bjp2FillCondition);
77 
78  _minbWriter->Init();
79  _bht1Writer->Init();
80  _bht2Writer->Init();
81  _bjp1Writer->Init();
82  _bjp2Writer->Init();
83 
84  return kStOk;
85  }
86 
87  Int_t Make()
88  {
89  _minbWriter->Make();
90  _bht1Writer->Make();
91  _bht2Writer->Make();
92  _bjp1Writer->Make();
93  _bjp2Writer->Make();
94 
95  return kStOk;
96  }
97 
98  Int_t Finish()
99  {
100  _minbWriter->Finish();
101  _bht1Writer->Finish();
102  _bht2Writer->Finish();
103  _bjp1Writer->Finish();
104  _bjp2Writer->Finish();
105 
106  return kStOk;
107  }
108 
109  ClassDef(StjTrigger2005MCMaker, 0)
110 
111 };
Definition: StjTrg.h:11
StMaker(const char *name="", const char *dummy=0)
Constructor & Destructor.
Definition: StMaker.cxx:188
Definition: Stypes.h:41