CMS 3D CMS Logo

List of all members | Public Member Functions | Public Attributes
pt_data Class Reference

#include <CSCTrackFinderDataTypes.h>

Public Member Functions

pt_dataoperator= (const unsigned short &)
 
 pt_data ()
 
 pt_data (const unsigned short &us)
 
unsigned short toint () const
 

Public Attributes

unsigned short charge_valid_front: 1
 
unsigned short charge_valid_rear: 1
 
unsigned short front_rank: 7
 
unsigned short rear_rank: 7
 

Detailed Description

Definition at line 113 of file CSCTrackFinderDataTypes.h.

Constructor & Destructor Documentation

◆ pt_data() [1/2]

pt_data::pt_data ( )
inline

Definition at line 120 of file CSCTrackFinderDataTypes.h.

◆ pt_data() [2/2]

pt_data::pt_data ( const unsigned short &  us)
inline

Definition at line 121 of file CSCTrackFinderDataTypes.h.

121 { this->operator=(us); }

References operator=().

Member Function Documentation

◆ operator=()

pt_data & pt_data::operator= ( const unsigned short &  us)

Definition at line 62 of file CSCTrackFinderDataTypes.cc.

62  {
63  this->front_rank = ((1 << 7) - 1) & us;
64  this->charge_valid_front = ((1 << 1) - 1) & (us >> 7);
65  this->rear_rank = ((1 << 7) - 1) & (us >> 8);
66  this->charge_valid_rear = ((1 << 1) - 1) & (us >> 15);
67 
68  return *this;
69 }

References charge_valid_front, charge_valid_rear, front_rank, and rear_rank.

Referenced by pt_data().

◆ toint()

unsigned short pt_data::toint ( ) const

Definition at line 89 of file CSCTrackFinderDataTypes.cc.

89  {
90  unsigned short us = 0;
91  us = front_rank | (charge_valid_front << 7) | (rear_rank << 8) | (charge_valid_rear << 15);
92  return us;
93 }

References charge_valid_front, charge_valid_rear, front_rank, and rear_rank.

Member Data Documentation

◆ charge_valid_front

unsigned short pt_data::charge_valid_front

Definition at line 116 of file CSCTrackFinderDataTypes.h.

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

◆ charge_valid_rear

unsigned short pt_data::charge_valid_rear

Definition at line 118 of file CSCTrackFinderDataTypes.h.

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

◆ front_rank

unsigned short pt_data::front_rank

Definition at line 115 of file CSCTrackFinderDataTypes.h.

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

◆ rear_rank

unsigned short pt_data::rear_rank

Definition at line 117 of file CSCTrackFinderDataTypes.h.

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

pt_data::operator=
pt_data & operator=(const unsigned short &)
Definition: CSCTrackFinderDataTypes.cc:62
pt_data::front_rank
unsigned short front_rank
Definition: CSCTrackFinderDataTypes.h:115
pt_data::rear_rank
unsigned short rear_rank
Definition: CSCTrackFinderDataTypes.h:117
pt_data::charge_valid_rear
unsigned short charge_valid_rear
Definition: CSCTrackFinderDataTypes.h:118
pt_data::charge_valid_front
unsigned short charge_valid_front
Definition: CSCTrackFinderDataTypes.h:116