CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
DTSectCollPhCand.h
Go to the documentation of this file.
1 //-------------------------------------------------
2 //
11 //
12 //--------------------------------------------------
13 #ifndef DT_SECT_COLL_PH_CAND_H
14 #define DT_SECT_COLL_PH_CAND_H
15 
16 
17 //----------------------
18 // Base Class Headers --
19 //----------------------
25 //---------------
26 // C++ Headers --
27 //---------------
28 #include <string>
29 
30 // ---------------------
31 // -- Class Interface --
32 // ---------------------
33 
35 
36  public:
37 
39  DTSectCollPhCand(DTSC* , const DTChambPhSegm*, int);
40 
43 
45  DTSectCollPhCand(const DTSectCollPhCand& tsccand);
46 
49 
52 
53  // Non-const methods
54 
56  void setBitsSectColl();
57 
59  void clearBits(){ _dataword.assign(5,3,0x7); }
60 
62  void clearBitsSectColl(){ _dataword.assign(0,13,0x1fff); }
63 
65  void setSecondTrack() { _dataword.set(14); _isCarry=1; }
66 
68  void resetCarry() { _isCarry=0; }
69 
71 
72 
74  inline void clear();
75 
76  // Const methods
77 
79  inline DTConfigSectColl* config() const { return _tsc->config(); }
80 
82  inline DTSC* tsc() const { return _tsc; }
83 
85  inline int isFirst() const { return _dataword.element(14)==0; }
86 
88  inline const DTChambPhSegm* tsTr() const { return _tsmsegm; }
89 
91  inline unsigned dataword() const { return _dataword.dataWord(0)&0x1ff; }
92 
94  bool operator < (const DTSectCollPhCand& c) const { return _dataword<c._dataword; }
95 
97  bool operator <= (const DTSectCollPhCand& c) const { return _dataword<=c._dataword; }
98 
100  void print() const;
101 
103  int CoarseSync() const;
104 
105 
106  private:
107 
110 
111  // BitArray<9> _dataword; // the word on which sorting is done
112  BitArray<15> _dataword; // the word on which sorting is done. reserve space enough for Preview and full data
113 
114  int _isCarry;
115 
116 };
117 #endif
const DTChambPhSegm * _tsmsegm
~DTSectCollPhCand()
Destructor.
DTSectCollPhCand & operator=(const DTSectCollPhCand &tsccand)
Assignment operator.
const DTChambPhSegm * tsTr() const
Return associated TSPhi trigger.
void clear()
Set the SC Candidate step.
int isFirst() const
Return first/second track bit value.
void clearBitsSectColl()
Clear (set to 1) the quality bits for Sector Collector.
Definition: DTSC.h:43
DTSC * tsc() const
Return the DTTSS.
unsigned dataword() const
Return an uint16 with the content of the data word (for debugging)
void setBitsSectColl()
Set the bits for DTTSM analysis.
void print() const
Print the trigger.
DTSectCollPhCand()
Constructor.
int CoarseSync() const
Return the Coarse Sync Parameter.
void clearBits()
Clear (set to 1) the quality bits (but first/second track bit)
void resetCarry()
Reset the carry bit.
unsigned dataWord(const int i) const
Definition: BitArray.h:128
bool operator<=(const DTSectCollPhCand &c) const
Operator &lt;= used for sorting.
int element(const int pos) const
Definition: BitArray.h:210
DTConfigSectColl * config() const
Configuration set.
void assign(const int p, const int n, const int val)
Definition: BitArray.h:239
DTConfigSectColl * config() const
Configuration set.
Definition: DTSC.h:87
BitArray< 15 > _dataword
void setSecondTrack()
Set the first track bit to second track (used for carry)
void set(const int i)
Definition: BitArray.h:230
bool operator<(const DTSectCollPhCand &c) const
Operator &lt; used for sorting.