1 |
#include "../interface/TRootSignalEvent.h"
|
2 |
|
3 |
ClassImp(TRootSignalEvent)
|
4 |
|
5 |
|
6 |
TRootSignalEvent::TRootSignalEvent() : nZ_(0), nMuplus_(0), nMuminus_(0), nFSR_(0), nISR_(0)
|
7 |
{
|
8 |
//cout << "Constructor TRootSignalEvent" << endl;
|
9 |
bosonZ_ = 0;
|
10 |
muplus_ = 0;
|
11 |
muminus_ = 0;
|
12 |
photonFSR_ = new TObjArray();
|
13 |
photonISR_ = new TObjArray();
|
14 |
}
|
15 |
|
16 |
TRootSignalEvent::~TRootSignalEvent()
|
17 |
{
|
18 |
//cout << "Destructor TRootSignalEvent" << endl;
|
19 |
if (bosonZ_) delete bosonZ_;
|
20 |
if (muminus_) delete muminus_;
|
21 |
if (muplus_) delete muplus_;
|
22 |
photonFSR_->Delete();
|
23 |
delete photonFSR_;
|
24 |
photonISR_->Delete();
|
25 |
delete photonISR_;
|
26 |
}
|
27 |
|
28 |
|
29 |
void TRootSignalEvent::addBosonZ(TRootParticle* part)
|
30 |
{
|
31 |
if (nZ_>0)
|
32 |
{
|
33 |
cout << "*** WARNING TRootSignalEvent *** More than one Z boson has been found" << endl;
|
34 |
delete part;
|
35 |
}
|
36 |
else
|
37 |
{
|
38 |
bosonZ_ = part;
|
39 |
}
|
40 |
nZ_++;
|
41 |
}
|
42 |
|
43 |
void TRootSignalEvent::addMuplus(TRootParticle* part)
|
44 |
{
|
45 |
if (nMuplus_>0)
|
46 |
{
|
47 |
cout << "*** WARNING TRootSignalEvent *** More than one mu+ coming from Z boson has been found" << endl;
|
48 |
delete part;
|
49 |
}
|
50 |
else
|
51 |
{
|
52 |
muplus_ = part;
|
53 |
}
|
54 |
nMuplus_++;
|
55 |
}
|
56 |
|
57 |
void TRootSignalEvent::addMuminus(TRootParticle* part)
|
58 |
{
|
59 |
if (nMuminus_>0)
|
60 |
{
|
61 |
cout << "*** WARNING TRootSignalEvent *** More than one mu- coming from Z boson has been found" << endl;
|
62 |
delete part;
|
63 |
}
|
64 |
else
|
65 |
{
|
66 |
muminus_ = part;
|
67 |
}
|
68 |
nMuminus_++;
|
69 |
}
|
70 |
|
71 |
void TRootSignalEvent::addFSR(TRootParticle* part)
|
72 |
{
|
73 |
photonFSR_->AddLast(part);
|
74 |
nFSR_++;
|
75 |
}
|
76 |
|
77 |
|
78 |
void TRootSignalEvent::addISR(TRootParticle* part)
|
79 |
{
|
80 |
photonISR_->AddLast(part);
|
81 |
nISR_++;
|
82 |
}
|
83 |
|
84 |
|
85 |
TRootParticle* TRootSignalEvent::photonFSR(Int_t iFSR)
|
86 |
{
|
87 |
if (iFSR<nFSR_)
|
88 |
{
|
89 |
return (TRootParticle*)(photonFSR_->At(iFSR));
|
90 |
}
|
91 |
else
|
92 |
{
|
93 |
cout << "*** ERROR in TRootSignalEvent::photonFSR *** iFSR >= nFSR_" << endl;
|
94 |
return 0;
|
95 |
}
|
96 |
}
|
97 |
|
98 |
TRootParticle* TRootSignalEvent::photonISR(Int_t iISR)
|
99 |
{
|
100 |
if (iISR<nISR_)
|
101 |
{
|
102 |
return (TRootParticle*)(photonISR_->At(iISR));
|
103 |
}
|
104 |
else
|
105 |
{
|
106 |
cout << "*** ERROR in TRootSignalEvent::photonISR *** iISR >= nISR_" << endl;
|
107 |
return 0;
|
108 |
}
|
109 |
}
|
110 |
|