CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
HGCalBestChoiceCodecImpl.h
Go to the documentation of this file.
1 #ifndef __L1Trigger_L1THGCal_HGCalBestChoiceCodecImpl_h__
2 #define __L1Trigger_L1THGCal_HGCalBestChoiceCodecImpl_h__
3 
4 
8 
9 #include <array>
10 #include <vector>
11 
12 
14 {
15  static const size_t size = 116;
16  typedef std::array<uint32_t, size> trigger_cell_list; // list of trigger cell values
18 
19  void reset()
20  {
21  payload.fill(0);
22  }
23 };
24 
25 
26 
28 {
29  public:
31 
33 
34  std::vector<bool> encode(const data_type&) const ;
35  data_type decode(const std::vector<bool>&) const;
36 
37  void linearize(const std::vector<HGCDataFrame<HGCalDetId,HGCSample>>&,
38  std::vector<std::pair<HGCalDetId, uint32_t > >&);
39 
41  const std::vector<std::pair<HGCalDetId, uint32_t > >&,
42  data_type&);
44 
45  // Retrieve parameters
46  size_t nData() const {return nData_;}
47  size_t dataLength() const {return dataLength_;}
48  double linLSB() const {return linLSB_;}
49  double adcsaturation() const {return adcsaturation_;}
50  uint32_t adcnBits() const {return adcnBits_;}
51  double tdcsaturation() const {return tdcsaturation_;}
52  uint32_t tdcnBits() const {return tdcnBits_;}
53  double tdcOnsetfC() const {return tdcOnsetfC_;}
56 
57 
58  private:
59  size_t nData_;
60  size_t dataLength_;
62  double linLSB_;
64  uint32_t adcnBits_;
65  double tdcsaturation_ ;
66  uint32_t tdcnBits_ ;
67  double tdcOnsetfC_ ;
68  double adcLSB_;
69  double tdcLSB_;
72 
73 };
74 
75 #endif
data_type decode(const std::vector< bool > &) const
std::vector< bool > encode(const data_type &) const
uint32_t triggerCellSaturationBits() const
HGCalBestChoiceCodecImpl(const edm::ParameterSet &conf)
std::array< uint32_t, size > trigger_cell_list
void linearize(const std::vector< HGCDataFrame< HGCalDetId, HGCSample >> &, std::vector< std::pair< HGCalDetId, uint32_t > > &)
void triggerCellSums(const HGCalTriggerGeometryBase &, const std::vector< std::pair< HGCalDetId, uint32_t > > &, data_type &)
HGCalBestChoiceDataPayload data_type
uint32_t triggerCellTruncationBits() const