CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
List of all members | Classes | Public Types | Public Member Functions | Private Attributes | Static Private Attributes
DTDigiSimLink Class Reference

#include <DTDigiSimLink.h>

Classes

struct  ChannelPacking
 

Public Types

typedef uint32_t ChannelType
 

Public Member Functions

ChannelType channel () const
 
uint32_t countsTDC () const
 
 DTDigiSimLink (int wireNr, int digiNr, int nTDC, unsigned int trackId, EncodedEventId evId, int base=32)
 
 DTDigiSimLink (int wireNr, int digiNr, double tdrift, unsigned int trackId, EncodedEventId evId, int base=32)
 
 DTDigiSimLink ()
 
EncodedEventId eventId () const
 
int number () const
 
unsigned int SimTrackId () const
 
double time () const
 
int wire () const
 

Private Attributes

int32_t theCounts
 
uint8_t theDigiNumber
 
EncodedEventId theEventId
 
uint32_t theSimTrackId
 
uint8_t theTDCBase
 
uint16_t theWire
 

Static Private Attributes

static const double reso
 

Detailed Description

Definition at line 6 of file DTDigiSimLink.h.

Member Typedef Documentation

typedef uint32_t DTDigiSimLink::ChannelType

Definition at line 8 of file DTDigiSimLink.h.

Constructor & Destructor Documentation

DTDigiSimLink::DTDigiSimLink ( int  wireNr,
int  digiNr,
int  nTDC,
unsigned int  trackId,
EncodedEventId  evId,
int  base = 32 
)
explicit

Definition at line 5 of file DTDigiSimLink.cc.

6  : theWire(wireNr),
7  theDigiNumber(digiNr),
9  theCounts(nTDC),
10  theSimTrackId(trackId),
11  theEventId(evId) {}
tuple base
Main Program
Definition: newFWLiteAna.py:92
DTDigiSimLink::DTDigiSimLink ( int  wireNr,
int  digiNr,
double  tdrift,
unsigned int  trackId,
EncodedEventId  evId,
int  base = 32 
)
explicit

Definition at line 13 of file DTDigiSimLink.cc.

14  : theWire(wireNr),
15  theDigiNumber(digiNr),
17  theCounts(static_cast<int>(tdrift * base / 25.)),
18  theSimTrackId(trackId),
19  theEventId(evId) {}
tuple base
Main Program
Definition: newFWLiteAna.py:92
DTDigiSimLink::DTDigiSimLink ( )

Definition at line 21 of file DTDigiSimLink.cc.

Member Function Documentation

DTDigiSimLink::ChannelType DTDigiSimLink::channel ( ) const

Definition at line 24 of file DTDigiSimLink.cc.

References DTDigiSimLink::ChannelPacking::num, mps_fire::result, theDigiNumber, theWire, and DTDigiSimLink::ChannelPacking::wi.

24  {
25 #pragma GCC diagnostic push
26 #pragma GCC diagnostic ignored "-Wuninitialized"
27  ChannelPacking result;
28  result.wi = theWire;
29  result.num = theDigiNumber;
30  DTDigiSimLink::ChannelType* p_result = reinterpret_cast<DTDigiSimLink::ChannelType*>(&result);
31  return *p_result;
32 #pragma GCC diagnostic pop
33 }
tuple result
Definition: mps_fire.py:311
uint32_t DTDigiSimLink::countsTDC ( ) const

Definition at line 39 of file DTDigiSimLink.cc.

References theCounts.

39 { return theCounts; }
EncodedEventId DTDigiSimLink::eventId ( ) const

Definition at line 45 of file DTDigiSimLink.cc.

References theEventId.

Referenced by ntupleDataFormat.Event::eventIdStr(), and operator<<().

45 { return theEventId; }
int DTDigiSimLink::number ( ) const

Definition at line 37 of file DTDigiSimLink.cc.

References theDigiNumber.

Referenced by operator<<().

37 { return theDigiNumber; }
unsigned int DTDigiSimLink::SimTrackId ( ) const

Definition at line 43 of file DTDigiSimLink.cc.

References theSimTrackId.

Referenced by operator<<().

43 { return theSimTrackId; }
double DTDigiSimLink::time ( ) const

Definition at line 41 of file DTDigiSimLink.cc.

References theCounts, and theTDCBase.

Referenced by operator<<().

41 { return theCounts * 25. / theTDCBase; }
int DTDigiSimLink::wire ( ) const

Definition at line 35 of file DTDigiSimLink.cc.

References theWire.

Referenced by operator<<().

35 { return theWire; }

Member Data Documentation

const double DTDigiSimLink::reso
staticprivate

Definition at line 53 of file DTDigiSimLink.h.

int32_t DTDigiSimLink::theCounts
private

Definition at line 59 of file DTDigiSimLink.h.

Referenced by countsTDC(), and time().

uint8_t DTDigiSimLink::theDigiNumber
private

Definition at line 57 of file DTDigiSimLink.h.

Referenced by channel(), and number().

EncodedEventId DTDigiSimLink::theEventId
private

Definition at line 61 of file DTDigiSimLink.h.

Referenced by eventId().

uint32_t DTDigiSimLink::theSimTrackId
private

Definition at line 60 of file DTDigiSimLink.h.

Referenced by SimTrackId().

uint8_t DTDigiSimLink::theTDCBase
private

Definition at line 58 of file DTDigiSimLink.h.

Referenced by time().

uint16_t DTDigiSimLink::theWire
private

Definition at line 56 of file DTDigiSimLink.h.

Referenced by channel(), and wire().