CMS 3D CMS Logo

List of all members | Public Member Functions | Private Attributes
CTPPSDiamondDigi Class Reference

#include <CTPPSDiamondDigi.h>

Public Member Functions

 CTPPSDiamondDigi (unsigned int ledgt_, unsigned int tedgt_, unsigned int threvolt, bool mhit_, unsigned short hptdcerror_)
 
 CTPPSDiamondDigi ()
 
HPTDCErrorFlags hptdcErrorFlags () const
 
unsigned int leadingEdge () const
 Return digi values number. More...
 
bool multipleHit () const
 
bool operator== (const CTPPSDiamondDigi &digi) const
 Digis are equal if they are have same ledt and tedt, threshold voltage, multihit flag, hptdcerror flags. More...
 
void setHPTDCErrorFlags (const HPTDCErrorFlags &hptdcerror_)
 
void setLeadingEdge (unsigned int ledgt_)
 Set digi values. More...
 
void setMultipleHit (bool mhit_)
 
void setThresholdVoltage (unsigned int threvolt_)
 
void setTrailingEdge (unsigned int tedgt_)
 
unsigned int thresholdVoltage () const
 
unsigned int trailingEdge () const
 
 ~CTPPSDiamondDigi ()
 

Private Attributes

HPTDCErrorFlags hptdcerror
 
unsigned int ledgt
 
bool mhit
 
unsigned int tedgt
 
unsigned int threvolt
 

Detailed Description

Digi Class for CTPPS Timing Detector

Author
Seyed Mohsen Etesami March 2016

Definition at line 16 of file CTPPSDiamondDigi.h.

Constructor & Destructor Documentation

CTPPSDiamondDigi::CTPPSDiamondDigi ( unsigned int  ledgt_,
unsigned int  tedgt_,
unsigned int  threvolt,
bool  mhit_,
unsigned short  hptdcerror_ 
)

Definition at line 11 of file CTPPSDiamondDigi.cc.

13  : ledgt(ledgt_), tedgt(tedgt_), threvolt(threvolt_), mhit(mhit_), hptdcerror(HPTDCErrorFlags(hptdcerror_)) {}
unsigned int ledgt
unsigned int tedgt
unsigned int threvolt
HPTDCErrorFlags hptdcerror
CTPPSDiamondDigi::CTPPSDiamondDigi ( )

Definition at line 15 of file CTPPSDiamondDigi.cc.

15 : ledgt(0), tedgt(0), threvolt(0), mhit(false), hptdcerror(HPTDCErrorFlags(0)) {}
unsigned int ledgt
unsigned int tedgt
unsigned int threvolt
HPTDCErrorFlags hptdcerror
CTPPSDiamondDigi::~CTPPSDiamondDigi ( )
inline

Definition at line 21 of file CTPPSDiamondDigi.h.

References operator==().

21 {};

Member Function Documentation

HPTDCErrorFlags CTPPSDiamondDigi::hptdcErrorFlags ( ) const
inline

Definition at line 36 of file CTPPSDiamondDigi.h.

References hptdcerror.

Referenced by operator<(), operator<<(), and operator==().

36 { return hptdcerror; }
HPTDCErrorFlags hptdcerror
unsigned int CTPPSDiamondDigi::leadingEdge ( ) const
inline

Return digi values number.

Definition at line 28 of file CTPPSDiamondDigi.h.

References ledgt.

Referenced by operator<(), operator<<(), and operator==().

28 { return ledgt; }
unsigned int ledgt
bool CTPPSDiamondDigi::multipleHit ( ) const
inline

Definition at line 34 of file CTPPSDiamondDigi.h.

References mhit.

Referenced by operator<(), operator<<(), and operator==().

34 { return mhit; }
bool CTPPSDiamondDigi::operator== ( const CTPPSDiamondDigi digi) const

Digis are equal if they are have same ledt and tedt, threshold voltage, multihit flag, hptdcerror flags.

Definition at line 18 of file CTPPSDiamondDigi.cc.

References HPTDCErrorFlags::errorFlag(), hptdcerror, hptdcErrorFlags(), leadingEdge(), ledgt, mhit, multipleHit(), tedgt, thresholdVoltage(), threvolt, and trailingEdge().

Referenced by ~CTPPSDiamondDigi().

18  {
19  if (ledgt != digi.leadingEdge() || tedgt != digi.trailingEdge() || threvolt != digi.thresholdVoltage() ||
20  mhit != digi.multipleHit() || hptdcerror.errorFlag() != digi.hptdcErrorFlags().errorFlag())
21  return false;
22  else
23  return true;
24 }
unsigned short errorFlag() const
unsigned int ledgt
unsigned int tedgt
unsigned int threvolt
unsigned int trailingEdge() const
HPTDCErrorFlags hptdcerror
unsigned int leadingEdge() const
Return digi values number.
bool multipleHit() const
unsigned int thresholdVoltage() const
HPTDCErrorFlags hptdcErrorFlags() const
void CTPPSDiamondDigi::setHPTDCErrorFlags ( const HPTDCErrorFlags hptdcerror_)
inline

Definition at line 43 of file CTPPSDiamondDigi.h.

References hptdcerror.

43 { hptdcerror = hptdcerror_; }
HPTDCErrorFlags hptdcerror
void CTPPSDiamondDigi::setLeadingEdge ( unsigned int  ledgt_)
inline

Set digi values.

Definition at line 39 of file CTPPSDiamondDigi.h.

References ledgt.

39 { ledgt = ledgt_; }
unsigned int ledgt
void CTPPSDiamondDigi::setMultipleHit ( bool  mhit_)
inline

Definition at line 42 of file CTPPSDiamondDigi.h.

References mhit.

42 { mhit = mhit_; }
void CTPPSDiamondDigi::setThresholdVoltage ( unsigned int  threvolt_)
inline

Definition at line 41 of file CTPPSDiamondDigi.h.

41 { threvolt = threvolt_; }
unsigned int threvolt
void CTPPSDiamondDigi::setTrailingEdge ( unsigned int  tedgt_)
inline

Definition at line 40 of file CTPPSDiamondDigi.h.

References tedgt.

40 { tedgt = tedgt_; }
unsigned int tedgt
unsigned int CTPPSDiamondDigi::thresholdVoltage ( ) const
inline

Definition at line 32 of file CTPPSDiamondDigi.h.

References threvolt.

Referenced by operator<(), operator<<(), and operator==().

32 { return threvolt; }
unsigned int threvolt
unsigned int CTPPSDiamondDigi::trailingEdge ( ) const
inline

Definition at line 30 of file CTPPSDiamondDigi.h.

References tedgt.

Referenced by operator<(), operator<<(), and operator==().

30 { return tedgt; }
unsigned int tedgt

Member Data Documentation

HPTDCErrorFlags CTPPSDiamondDigi::hptdcerror
private

Definition at line 54 of file CTPPSDiamondDigi.h.

Referenced by hptdcErrorFlags(), operator==(), and setHPTDCErrorFlags().

unsigned int CTPPSDiamondDigi::ledgt
private

Definition at line 47 of file CTPPSDiamondDigi.h.

Referenced by leadingEdge(), operator==(), and setLeadingEdge().

bool CTPPSDiamondDigi::mhit
private

Definition at line 53 of file CTPPSDiamondDigi.h.

Referenced by multipleHit(), operator==(), and setMultipleHit().

unsigned int CTPPSDiamondDigi::tedgt
private

Definition at line 49 of file CTPPSDiamondDigi.h.

Referenced by operator==(), setTrailingEdge(), and trailingEdge().

unsigned int CTPPSDiamondDigi::threvolt
private

Definition at line 51 of file CTPPSDiamondDigi.h.

Referenced by operator==(), and thresholdVoltage().