CGEM BOSS 6.6.5.g
BESIII Offline Software System
Loading...
Searching...
No Matches
PmtData Class Reference

#include <TofData.h>

Public Member Functions

 PmtData ()
 
 ~PmtData ()
 
PmtDataoperator= (const PmtData &source)
 
unsigned int iden () const
 
unsigned int times () const
 
int adcChannel ()
 
void calculate (bool barrel, int tofid, bool east, int m_identify)
 
double qtc ()
 
double adc ()
 
int qclock ()
 
int tdcChannel ()
 
double tdc ()
 
int tclock ()
 
unsigned int quality () const
 
void timespp ()
 
void timesmm ()
 
int qtimes ()
 
void qtimespp ()
 
void qtimesmm ()
 
int ttimes ()
 
void ttimespp ()
 
void ttimesmm ()
 
int qnumber ()
 
int tnumber ()
 
bool qused ()
 
bool tused ()
 
bool used ()
 
void setIdentify (unsigned int iden)
 
void setAdc (Adc *adc)
 
void setTdc (Tdc *tdc)
 
void setUsed ()
 
void clear ()
 

Detailed Description

Definition at line 70 of file TofData.h.

Constructor & Destructor Documentation

◆ PmtData()

PmtData::PmtData ( )

Definition at line 183 of file TofData.cxx.

183 {
184 m_iden_value = 0;
185 m_times = 0;
186 m_quality = 0;
187 m_adc = 0;
188 m_tdc = 0;
189}

◆ ~PmtData()

PmtData::~PmtData ( )

Definition at line 192 of file TofData.cxx.

192 {
194}
void clear()
Definition: TofData.cxx:429

Member Function Documentation

◆ adc()

double PmtData::adc ( )

Definition at line 238 of file TofData.cxx.

238 {
239 double value = -999.0;
240 if( m_adc ) {
241 value = m_adc->value();
242 }
243 else {
244 if( m_tdc ) {
245 value = 10000.0;
246 }
247 }
248 return value;
249}
double value() const
Definition: TofData.h:21

Referenced by TofData::adc(), TofData::adc1(), TofData::adc2(), TofData::data(), setAdc(), and TofRawDataProvider::tofDataMapFull().

◆ adcChannel()

int PmtData::adcChannel ( )

Definition at line 207 of file TofData.cxx.

207 {
208 int channel = -999;
209 if( m_adc ) {
210 channel = m_adc->channel();
211 }
212 return channel;
213}
int channel() const
Definition: TofData.h:17

Referenced by TofData::adcChannel(), TofData::adcChannelEast(), and TofData::adcChannelWest().

◆ calculate()

void PmtData::calculate ( bool  barrel,
int  tofid,
bool  east,
int  m_identify 
)

Definition at line 216 of file TofData.cxx.

216 {
217 if( m_adc ) {
218 m_adc->calculate( barrel, tofid, east,identify );
219 }
220 return;
221}
void calculate(bool barrel, int tofid, bool east, int identify)
Definition: TofData.cxx:122

Referenced by TofData::setBackward(), and TofData::setForward().

◆ clear()

void PmtData::clear ( )

Definition at line 429 of file TofData.cxx.

429 {
430 if( m_adc ) {
431 if( m_adc->times() <= 1 ) {
432 delete m_adc;
433 m_adc = 0;
434 }
435 else {
436 m_adc->timesmm();
437 }
438 }
439 if( m_tdc ) {
440 if( m_tdc->times() <= 1 ) {
441 delete m_tdc;
442 m_tdc = 0;
443 }
444 else {
445 m_tdc->timesmm();
446 }
447 }
448 return;
449}
void timesmm()
Definition: TofData.cxx:42
int times() const
Definition: TofData.h:18

Referenced by ~PmtData().

◆ iden()

unsigned int PmtData::iden ( ) const
inline

Definition at line 78 of file TofData.h.

78{ return m_iden_value; }

Referenced by setIdentify().

◆ operator=()

PmtData & PmtData::operator= ( const PmtData source)

Definition at line 197 of file TofData.cxx.

197 {
198 m_iden_value = source.m_iden_value;
199 m_times = source.m_times;
200 m_quality = source.m_quality;
201 m_adc = source.m_adc;
202 m_tdc = source.m_tdc;
203 return *this;
204}

◆ qclock()

int PmtData::qclock ( )

Definition at line 252 of file TofData.cxx.

252 {
253 int clock = -999;
254 if( m_adc ) {
255 clock = m_adc->clock();
256 }
257 return clock;
258}
int clock() const
Definition: TofData.h:20

Referenced by TofData::qclock(), TofData::qclock1(), and TofData::qclock2().

◆ qnumber()

int PmtData::qnumber ( )

Definition at line 350 of file TofData.cxx.

350 {
351 int number = 0;
352 if( m_adc ) {
353 number = m_adc->number();
354 }
355 return number;
356}
int number() const
Definition: TofData.h:19

Referenced by TofData::qnumber1(), and TofData::qnumber2().

◆ qtc()

double PmtData::qtc ( )

Definition at line 224 of file TofData.cxx.

224 {
225 double value = -999.0;
226 if( m_adc ) {
227 value = m_adc->qtc();
228 }
229 else {
230 if( m_tdc ) {
231 value = 10000.0;
232 }
233 }
234 return value;
235}
double qtc() const
Definition: TofData.h:55

Referenced by TofData::qtc(), TofData::qtc1(), and TofData::qtc2().

◆ qtimes()

int PmtData::qtimes ( )

Definition at line 332 of file TofData.cxx.

332 {
333 int times = -1;
334 if( m_adc ) {
335 times = m_adc->times();
336 }
337 return times;
338}
unsigned int times() const
Definition: TofData.h:79

Referenced by TofData::qtimes1(), and TofData::qtimes2().

◆ qtimesmm()

void PmtData::qtimesmm ( )

Definition at line 308 of file TofData.cxx.

308 {
309 if( m_adc ) {
310 m_adc->timesmm();
311 }
312 return;
313}

Referenced by TofRawDataProvider::tofDataMapFull().

◆ qtimespp()

void PmtData::qtimespp ( )

Definition at line 300 of file TofData.cxx.

300 {
301 if( m_adc ) {
302 m_adc->timespp();
303 }
304 return;
305}
void timespp()
Definition: TofData.cxx:36

Referenced by TofData::setBackward(), and TofData::setForward().

◆ quality()

unsigned int PmtData::quality ( ) const
inline

Definition at line 88 of file TofData.h.

88{ return m_quality; }

Referenced by TofData::setBackward(), TofData::setForward(), and TofRawDataProvider::tofDataMapFull().

◆ qused()

bool PmtData::qused ( )

Definition at line 368 of file TofData.cxx.

368 {
369 bool used = false;
370 if( m_adc ) {
371 used = m_adc->used();
372 }
373 return used;
374}
bool used()
Definition: TofData.cxx:386
bool used() const
Definition: TofData.h:22

Referenced by TofData::qused1(), and TofData::qused2().

◆ setAdc()

void PmtData::setAdc ( Adc adc)

Definition at line 398 of file TofData.cxx.

398 {
399 m_adc = adc;
400 if( adc->channel() != -999 ) {
401 if( m_adc->times() == -1 ) { m_adc->timespp(); }
402 m_quality = ( m_quality | 0x2 );
403 }
404 return;
405}
double adc()
Definition: TofData.cxx:238

Referenced by TofRawDataProvider::tofDataMapFull().

◆ setIdentify()

void PmtData::setIdentify ( unsigned int  iden)
inline

Definition at line 106 of file TofData.h.

106{ m_iden_value = iden; }
unsigned int iden() const
Definition: TofData.h:78

◆ setTdc()

void PmtData::setTdc ( Tdc tdc)

Definition at line 408 of file TofData.cxx.

408 {
409 m_tdc = tdc;
410 if( tdc->channel() != -999 ) {
411 if( m_tdc->times() == -1 ) { m_tdc->timespp(); }
412 m_quality = ( m_quality | 0x1 );
413 }
414 return;
415}
double tdc()
Definition: TofData.cxx:270

Referenced by TofRawDataProvider::tofDataMapFull(), and TofRawDataProvider::tofDataMapOnlineMode().

◆ setUsed()

void PmtData::setUsed ( )

Definition at line 418 of file TofData.cxx.

418 {
419 if( m_adc ) {
420 m_adc->setUsed( true );
421 }
422 if( m_tdc ) {
423 m_tdc->setUsed( true );
424 }
425 return;
426}
void setUsed(bool used)
Definition: TofData.h:28

Referenced by TofData::setUsed().

◆ tclock()

int PmtData::tclock ( )

Definition at line 279 of file TofData.cxx.

279 {
280 int clock = -999;
281 if( m_tdc ) {
282 clock = m_tdc->clock();
283 }
284 return clock;
285}

Referenced by TofData::tclock(), TofData::tclock1(), and TofData::tclock2().

◆ tdc()

double PmtData::tdc ( )

Definition at line 270 of file TofData.cxx.

270 {
271 double value = -999.;
272 if( m_tdc ) {
273 value = m_tdc->value();
274 }
275 return value;
276}

Referenced by TofData::data(), setTdc(), TofData::tdc(), TofData::tdc1(), TofData::tdc2(), and TofRawDataProvider::tofDataMapOnlineMode().

◆ tdcChannel()

int PmtData::tdcChannel ( )

Definition at line 261 of file TofData.cxx.

261 {
262 int channel = -999;
263 if( m_tdc ) {
264 channel = m_tdc->channel();
265 }
266 return channel;
267}

Referenced by TofData::tdcChannel(), TofData::tdcChannelEast(), and TofData::tdcChannelWest().

◆ times()

unsigned int PmtData::times ( ) const
inline

Definition at line 79 of file TofData.h.

79{ return m_times; }

Referenced by TofData::clear(), TofData::eastTimes(), qtimes(), ttimes(), and TofData::westTimes().

◆ timesmm()

void PmtData::timesmm ( )

Definition at line 294 of file TofData.cxx.

294 {
295 m_times = m_times - 1;
296 return;
297}

Referenced by TofData::clear().

◆ timespp()

void PmtData::timespp ( )

Definition at line 288 of file TofData.cxx.

288 {
289 m_times = m_times + 1;
290 return;
291}

Referenced by TofData::setBackward(), and TofData::setForward().

◆ tnumber()

int PmtData::tnumber ( )

Definition at line 359 of file TofData.cxx.

359 {
360 int number = 0;
361 if( m_tdc ) {
362 number = m_tdc->number();
363 }
364 return number;
365}

Referenced by TofData::tnumber1(), and TofData::tnumber2().

◆ ttimes()

int PmtData::ttimes ( )

Definition at line 341 of file TofData.cxx.

341 {
342 int times = -1;
343 if( m_tdc ) {
344 times = m_tdc->times();
345 }
346 return times;
347}

Referenced by TofData::ttimes1(), and TofData::ttimes2().

◆ ttimesmm()

void PmtData::ttimesmm ( )

Definition at line 324 of file TofData.cxx.

324 {
325 if( m_tdc ) {
326 m_tdc->timesmm();
327 }
328 return;
329}

◆ ttimespp()

void PmtData::ttimespp ( )

Definition at line 316 of file TofData.cxx.

316 {
317 if( m_tdc ) {
318 m_tdc->timespp();
319 }
320 return;
321}

Referenced by TofData::setBackward(), and TofData::setForward().

◆ tused()

bool PmtData::tused ( )

Definition at line 377 of file TofData.cxx.

377 {
378 bool used = false;
379 if( m_tdc ) {
380 used = m_tdc->used();
381 }
382 return used;
383}

Referenced by TofData::tused1(), and TofData::tused2().

◆ used()

bool PmtData::used ( )

Definition at line 386 of file TofData.cxx.

386 {
387 bool used = false;
388 if( m_adc ) {
389 used = ( used || m_adc->used() );
390 }
391 if( m_tdc ) {
392 used = ( used || m_tdc->used() );
393 }
394 return used;
395}

Referenced by qused(), tused(), used(), TofData::used(), TofData::used1(), and TofData::used2().


The documentation for this class was generated from the following files: