CMS 3D CMS Logo

L1GctInternJetData.h
Go to the documentation of this file.
1 #ifndef L1GCTINTERNJETDATA_H
2 #define L1GCTINTERNJETDATA_H
3 
4 #include <string>
5 
7 
13 
15 public:
17 
18 public:
21 
24  uint16_t capBlock,
25  uint16_t capIndex,
26  int16_t bx,
27  uint8_t sgnEta,
28  uint8_t oflow,
29  uint16_t et,
30  uint8_t eta,
31  uint8_t phi,
32  uint8_t tauVeto,
33  uint8_t rank);
34 
35  // 'named' constructors to avoid confusion
36 
37  // emulator calibrated jet ctor
39  int16_t bx,
40  uint16_t et,
41  bool overFlow,
42  bool tauVeto,
43  uint8_t eta,
44  uint8_t phi,
45  uint16_t rank);
46 
49  L1CaloRegionDetId rgn, uint16_t capBlock, uint16_t capIndex, int16_t bx, uint32_t data);
50 
53  L1CaloRegionDetId rgn, uint16_t capBlock, uint16_t capIndex, int16_t bx, uint32_t data);
54 
57  L1CaloRegionDetId rgn, uint16_t capBlock, uint16_t capIndex, int16_t bx, uint32_t data);
58 
61  L1CaloRegionDetId rgn, uint16_t capBlock, uint16_t capIndex, int16_t bx, uint32_t data);
62 
64  virtual ~L1GctInternJetData();
65 
66  // getters
67 
70 
72  L1CaloRegionDetId regionId() const { return regionId_; }
73 
75  bool empty() const { return (data_ == 0); }
76 
78  uint16_t capBlock() const { return capBlock_; }
79 
81  uint16_t capIndex() const { return capIndex_; }
82 
84  int16_t bx() const { return bx_; }
85 
87  uint32_t raw() const { return data_; }
88 
90  uint16_t rank() const { return data_ & 0x3f; }
91 
93  uint16_t tauVeto() const { return (data_ >> 6) & 0x1; }
94 
96  uint16_t phi() const { return (data_ >> 7) & 0x1f; }
97 
99  uint16_t eta() const { return (data_ >> 12) & 0xf; }
100 
102  uint16_t et() const { return (data_ >> 16) & 0xfff; }
103 
105  uint16_t oflow() const { return (data_ >> 28) & 0x1; }
106 
108  uint16_t sgnEta() const { return (data_ >> 29) & 0x1; }
109 
110  // setters
111 
114 
116  void setCapBlock(uint16_t capBlock) { capBlock_ = capBlock; }
117 
119  void setCapIndex(uint16_t capIndex) { capIndex_ = capIndex; }
120 
122  void setBx(uint16_t bx) { bx_ = bx; }
123 
126 
128  void setRawData(uint32_t data) { data_ = data; }
129 
131  void setData(uint8_t sgnEta, uint8_t oflow, uint16_t et, uint8_t eta, uint8_t phi, uint8_t tauVeto, uint8_t rank);
132 
133  // operators
134 
136  bool operator==(const L1GctInternJetData& c) const;
137 
139  bool operator!=(const L1GctInternJetData& c) const { return !(*this == c); }
140 
141 private:
142  // location in calorimeter (optionally set by unpacker)
144 
145  // source of the data
146  uint16_t capBlock_;
147  uint16_t capIndex_;
148  int16_t bx_;
149 
150  // type of data
152 
153  // the captured data
154  uint32_t data_;
155 };
156 
157 std::ostream& operator<<(std::ostream& s, const L1GctInternJetData& cand);
158 
159 #endif
L1GctInternJetData::fromJetClusterMinimal
static L1GctInternJetData fromJetClusterMinimal(L1CaloRegionDetId rgn, uint16_t capBlock, uint16_t capIndex, int16_t bx, uint32_t data)
construct from "jet_cluster_minimal"
Definition: L1GctInternJetData.cc:67
L1GctInternJetData::type
L1GctInternJetData::L1GctInternJetType type() const
'type' of object
Definition: L1GctInternJetData.h:69
L1GctInternJetData::jet_precluster
Definition: L1GctInternJetData.h:16
L1GctInternJetData::raw
uint32_t raw() const
get the raw data
Definition: L1GctInternJetData.h:87
L1GctInternJetData::jet_cluster
Definition: L1GctInternJetData.h:16
L1GctInternJetData::sgnEta
uint16_t sgnEta() const
get sign of eta
Definition: L1GctInternJetData.h:108
L1GctInternJetData::eta
uint16_t eta() const
get eta
Definition: L1GctInternJetData.h:99
L1GctInternJetData::setData
void setData(uint8_t sgnEta, uint8_t oflow, uint16_t et, uint8_t eta, uint8_t phi, uint8_t tauVeto, uint8_t rank)
construct data word from components
Definition: L1GctInternJetData.cc:100
L1GctInternJetData::bx_
int16_t bx_
Definition: L1GctInternJetData.h:148
L1GctInternJetData::L1GctInternJetData
L1GctInternJetData()
default constructor (for vector initialisation etc.)
Definition: L1GctInternJetData.cc:3
L1GctInternJetData::capBlock_
uint16_t capBlock_
Definition: L1GctInternJetData.h:146
L1GctInternJetData::fromJetPreCluster
static L1GctInternJetData fromJetPreCluster(L1CaloRegionDetId rgn, uint16_t capBlock, uint16_t capIndex, int16_t bx, uint32_t data)
construct from "jet_precluster"
Definition: L1GctInternJetData.cc:52
L1GctInternJetData::et
uint16_t et() const
get et
Definition: L1GctInternJetData.h:102
L1GctInternJetData::L1GctInternJetType
L1GctInternJetType
Definition: L1GctInternJetData.h:16
L1GctInternJetData::gct_trig_object
Definition: L1GctInternJetData.h:16
L1GctInternJetData::fromEmulator
static L1GctInternJetData fromEmulator(L1CaloRegionDetId rgn, int16_t bx, uint16_t et, bool overFlow, bool tauVeto, uint8_t eta, uint8_t phi, uint16_t rank)
Definition: L1GctInternJetData.cc:24
alignCSCRings.s
s
Definition: alignCSCRings.py:92
L1GctInternJetData::fromGctTrigObject
static L1GctInternJetData fromGctTrigObject(L1CaloRegionDetId rgn, uint16_t capBlock, uint16_t capIndex, int16_t bx, uint32_t data)
construct from "gct_trig_object"
Definition: L1GctInternJetData.cc:82
L1CaloRegionDetId
Definition: L1CaloRegionDetId.h:18
L1GctInternJetData::fromJetCluster
static L1GctInternJetData fromJetCluster(L1CaloRegionDetId rgn, uint16_t capBlock, uint16_t capIndex, int16_t bx, uint32_t data)
construct from "jet_cluster"
Definition: L1GctInternJetData.cc:37
L1GctInternJetData::setRegionId
void setRegionId(L1CaloRegionDetId rgn)
set region
Definition: L1GctInternJetData.h:113
L1GctInternJetData::empty
bool empty() const
was an object really found?
Definition: L1GctInternJetData.h:75
L1GctInternJetData::operator!=
bool operator!=(const L1GctInternJetData &c) const
inequality operator
Definition: L1GctInternJetData.h:139
L1GctInternJetData::~L1GctInternJetData
virtual ~L1GctInternJetData()
destructor (virtual to prevent compiler warnings)
Definition: L1GctInternJetData.cc:97
L1GctInternJetData::phi
uint16_t phi() const
get phi
Definition: L1GctInternJetData.h:96
L1GctInternJetData::bx
int16_t bx() const
get BX number
Definition: L1GctInternJetData.h:84
L1GctInternJetData::emulator
Definition: L1GctInternJetData.h:16
L1CaloRegionDetId.h
type
type
Definition: SiPixelVCal_PayloadInspector.cc:37
L1GctInternJetData::setRawData
void setRawData(uint32_t data)
set data
Definition: L1GctInternJetData.h:128
L1GctInternJetData::capIndex
uint16_t capIndex() const
get index within capture block
Definition: L1GctInternJetData.h:81
cand
Definition: decayParser.h:32
L1GctInternJetData::jet_cluster_minimal
Definition: L1GctInternJetData.h:16
HltBtagPostValidation_cff.c
c
Definition: HltBtagPostValidation_cff.py:31
L1GctInternJetData::setCapBlock
void setCapBlock(uint16_t capBlock)
set cap block
Definition: L1GctInternJetData.h:116
L1GctInternJetData::regionId_
L1CaloRegionDetId regionId_
Definition: L1GctInternJetData.h:143
L1GctInternJetData::capBlock
uint16_t capBlock() const
get capture block
Definition: L1GctInternJetData.h:78
L1GctInternJetData::regionId
L1CaloRegionDetId regionId() const
region associated with the candidate
Definition: L1GctInternJetData.h:72
L1GctInternJetData::rank
uint16_t rank() const
get rank bits
Definition: L1GctInternJetData.h:90
L1GctInternJetData::oflow
uint16_t oflow() const
get oflow
Definition: L1GctInternJetData.h:105
L1GctInternJetData::setCapIndex
void setCapIndex(uint16_t capIndex)
set cap index
Definition: L1GctInternJetData.h:119
data
char data[epos_bytes_allocation]
Definition: EPOS_Wrapper.h:79
operator<<
std::ostream & operator<<(std::ostream &s, const L1GctInternJetData &cand)
pretty print
Definition: L1GctInternJetData.cc:120
L1GctInternJetData::operator==
bool operator==(const L1GctInternJetData &c) const
equality operator
Definition: L1GctInternJetData.cc:115
L1GctInternJetData::setBx
void setBx(uint16_t bx)
set bx
Definition: L1GctInternJetData.h:122
L1GctInternJetData::type_
L1GctInternJetType type_
Definition: L1GctInternJetData.h:151
L1GctInternJetData::tauVeto
uint16_t tauVeto() const
get tau veto
Definition: L1GctInternJetData.h:93
L1GctInternJetData::data_
uint32_t data_
Definition: L1GctInternJetData.h:154
L1GctInternJetData::capIndex_
uint16_t capIndex_
Definition: L1GctInternJetData.h:147
L1GctInternJetData::setType
void setType(L1GctInternJetType type)
set type
Definition: L1GctInternJetData.h:125
L1GctInternJetData
L1 GCT internal jet candidate.
Definition: L1GctInternJetData.h:14