1 #ifndef ST_CHARGED_PION_EVENT_HH
2 #define ST_CHARGED_PION_EVENT_HH
12 #include "TClonesArray.h"
13 #include "StEvent/StRunInfo.h"
14 #include "StChargedPionBaseEv.h"
30 virtual void Clear(Option_t* =
"");
32 unsigned int runId()
const;
33 unsigned int eventId()
const;
34 unsigned int bx7()
const;
35 unsigned int bbcTimeBin()
const;
36 const string& muDstName()
const;
39 unsigned int spinBit()
const;
40 bool isSpinValid()
const;
41 bool isPolValid()
const;
42 bool isPolLong()
const;
43 bool isPolTrans()
const;
44 bool isBxingMasked()
const;
45 bool isNullOffset()
const;
47 bool isTrigger(
unsigned int trigId)
const;
48 bool isSimuTrigger(
unsigned int trigId)
const;
49 float prescale(
unsigned int trigId)
const;
51 int highTowerAdc(
short towerId)
const;
52 int triggerPatchAdc(
short patchId)
const;
53 int jetPatchAdc(
short patchId)
const;
55 unsigned int nVertices()
const;
56 TClonesArray* vertices();
57 const TClonesArray* vertices()
const;
59 unsigned int nTracks()
const;
60 TClonesArray* tracks();
61 const TClonesArray* tracks()
const;
63 unsigned int nJets()
const;
65 const TClonesArray* jets()
const;
76 void setRunId(
unsigned int);
77 void setEventId(
unsigned int);
78 void setBx7(
unsigned char);
79 void setBbcTimeBin(
unsigned short);
80 void setMuDstName(
const char*);
83 void setSpinBit(
unsigned char);
84 void setPolValid(
bool);
85 void setPolLong(
bool);
86 void setPolTrans(
bool);
87 void setBxingMasked(
bool);
88 void setBxingOffset(
int);
90 void addTrigger(
unsigned int);
91 void addSimuTrigger(
unsigned int);
92 void setPrescale(
unsigned int trigId,
float prescale);
94 void addHighTower(
short towerId,
int ADC);
95 void addTriggerPatch(
short patchId,
int ADC);
96 void addJetPatch(
short patchId,
int ADC);
99 void setL2Result(
const void *address,
bool emulated=
false);
109 UShort_t mBbcTimeBin;
117 map<unsigned int, float> mTriggerPrescales;
119 UInt_t mSimuTriggerBits;
121 map<short, int> mHighTowers;
122 map<short, int> mTriggerPatches;
123 map<short, int> mJetPatches;
127 UInt_t mL2ResultEmulated[9];
129 TClonesArray *mVertices;
130 TClonesArray *mTracks;
133 enum {kIsPolValid=0x01,
142 inline unsigned int StChargedPionEvent::runId()
const {
return mRunId; }
143 inline unsigned int StChargedPionEvent::eventId()
const {
return mEventId; }
144 inline unsigned int StChargedPionEvent::bx7()
const {
return mBx7; }
145 inline unsigned int StChargedPionEvent::bbcTimeBin()
const {
return mBbcTimeBin; }
146 inline const string& StChargedPionEvent::muDstName()
const {
return mMuDstName; }
147 inline const StRunInfo& StChargedPionEvent::runInfo()
const {
return mRunInfo; }
149 inline unsigned int StChargedPionEvent::spinBit()
const {
return mSpinBit; }
150 inline bool StChargedPionEvent::isPolValid()
const {
return mSpinQA & kIsPolValid; }
151 inline bool StChargedPionEvent::isPolLong()
const {
return mSpinQA & kIsPolLong; }
152 inline bool StChargedPionEvent::isPolTrans()
const {
return mSpinQA & kIsPolTrans; }
153 inline bool StChargedPionEvent::isBxingMasked()
const {
return mSpinQA & kIsBxingMasked; }
154 inline bool StChargedPionEvent::isNullOffset()
const {
return mSpinQA & kNullOffset; }
156 inline unsigned int StChargedPionEvent::
157 nVertices()
const {
return mVertices->GetEntriesFast(); }
159 inline TClonesArray* StChargedPionEvent::
160 vertices() {
return mVertices; }
162 inline const TClonesArray* StChargedPionEvent::
163 vertices()
const {
return mVertices; }
165 inline unsigned int StChargedPionEvent::
166 nTracks()
const {
return mTracks->GetEntriesFast(); }
168 inline TClonesArray* StChargedPionEvent::
169 tracks() {
return mTracks; }
171 inline const TClonesArray* StChargedPionEvent::
172 tracks()
const {
return mTracks; }
174 inline unsigned int StChargedPionEvent::
175 nJets()
const {
return mJets->GetEntriesFast(); }
177 inline TClonesArray* StChargedPionEvent::
178 jets() {
return mJets; }
180 inline const TClonesArray* StChargedPionEvent::
181 jets()
const {
return mJets; }
183 inline void StChargedPionEvent::setRunId(
unsigned int a) { mRunId = a; }
184 inline void StChargedPionEvent::setEventId(
unsigned int a) { mEventId = a; }
185 inline void StChargedPionEvent::setBx7(
unsigned char a) { mBx7 = a; }
186 inline void StChargedPionEvent::setBbcTimeBin(
unsigned short a) { mBbcTimeBin = a; }
187 inline void StChargedPionEvent::setMuDstName(
const char* a) { mMuDstName = a; }
188 inline void StChargedPionEvent::setRunInfo(
const StRunInfo& a) { mRunInfo = a; }
190 inline void StChargedPionEvent::
191 setSpinBit(
unsigned char a) { mSpinBit = a; }
193 inline void StChargedPionEvent::
194 setPolValid(
bool a) { a ? mSpinQA |= kIsPolValid : mSpinQA &= ~kIsPolValid; }
196 inline void StChargedPionEvent::
197 setPolLong(
bool a) { a ? mSpinQA |= kIsPolLong : mSpinQA &= ~kIsPolLong; }
199 inline void StChargedPionEvent::
200 setPolTrans(
bool a) { a ? mSpinQA |= kIsPolTrans : mSpinQA &= ~kIsPolTrans; }
202 inline void StChargedPionEvent::
203 setBxingMasked(
bool a) { a ? mSpinQA |= kIsBxingMasked : mSpinQA &= ~kIsBxingMasked; }
205 inline void StChargedPionEvent::
206 setBxingOffset(
int a) { (a==0) ? mSpinQA |= kNullOffset : mSpinQA &= ~kNullOffset; }
208 inline void StChargedPionEvent::
209 setPrescale(
unsigned int trigId,
float prescale) { mTriggerPrescales[trigId] = prescale; }
211 inline void StChargedPionEvent::
212 addHighTower(
short towerId,
int ADC) { mHighTowers[towerId] = ADC; }
214 inline void StChargedPionEvent::
215 addTriggerPatch(
short patchId,
int ADC) { mTriggerPatches[patchId] = ADC; }
217 inline void StChargedPionEvent::
218 addJetPatch(
short patchId,
int ADC) { mJetPatches[patchId] = ADC; }
void setL2Result(const void *address, bool emulated=false)
address to dijet result