CMS 3D CMS Logo

List of all members | Public Member Functions | Private Attributes
HcalTPGCompressor Class Reference

#include <HcalTPGCompressor.h>

Public Member Functions

void compress (const IntegerCaloSamples &ics, const std::vector< int > &fineGrain, HcalTriggerPrimitiveDigi &digi) const
 
HcalTriggerPrimitiveSample compress (const HcalTrigTowerDetId &id, unsigned int sample, bool fineGrain) const
 
 HcalTPGCompressor (const CaloTPGTranscoder *coder)
 

Private Attributes

const CaloTPGTranscodercoder_
 

Detailed Description

Author
J. Mans - Minnesota

Definition at line 12 of file HcalTPGCompressor.h.

Constructor & Destructor Documentation

◆ HcalTPGCompressor()

HcalTPGCompressor::HcalTPGCompressor ( const CaloTPGTranscoder coder)

Definition at line 4 of file HcalTPGCompressor.cc.

4 : coder_(coder) {}
const CaloTPGTranscoder * coder_

Member Function Documentation

◆ compress() [1/2]

void HcalTPGCompressor::compress ( const IntegerCaloSamples ics,
const std::vector< int > &  fineGrain,
HcalTriggerPrimitiveDigi digi 
) const

Definition at line 6 of file HcalTPGCompressor.cc.

References coder_, CaloTPGTranscoder::hcalCompress(), mps_fire::i, unpacker2007h4_cff::ics, HcalTriggerPrimitiveDigi::setPresamples(), HcalTriggerPrimitiveDigi::setSample(), and HcalTriggerPrimitiveDigi::setSize().

Referenced by HcalTriggerPrimitiveAlgo::analyze(), HcalTriggerPrimitiveAlgo::analyzeHF(), HcalTriggerPrimitiveAlgo::analyzeHF2016(), HcalTriggerPrimitiveAlgo::analyzeHFQIE10(), and HcalTriggerPrimitiveAlgo::analyzeQIE11().

8  {
9  digi.setSize(ics.size());
10  digi.setPresamples(ics.presamples());
11  for (int i = 0; i < ics.size(); i++)
12  digi.setSample(i, coder_->hcalCompress(ics.id(), ics[i], fineGrain[i]));
13 }
virtual HcalTriggerPrimitiveSample hcalCompress(const HcalTrigTowerDetId &id, unsigned int sample, int fineGrain) const =0
Compression from linear samples+fine grain in the HTR.
void setSample(int i, const HcalTriggerPrimitiveSample &sam)
const CaloTPGTranscoder * coder_

◆ compress() [2/2]

HcalTriggerPrimitiveSample HcalTPGCompressor::compress ( const HcalTrigTowerDetId id,
unsigned int  sample,
bool  fineGrain 
) const

Definition at line 15 of file HcalTPGCompressor.cc.

References coder_, CaloTPGTranscoder::hcalCompress(), and ecalGpuTask_cfi::sample.

17  {
18  return coder_->hcalCompress(id, sample, fineGrain);
19 }
virtual HcalTriggerPrimitiveSample hcalCompress(const HcalTrigTowerDetId &id, unsigned int sample, int fineGrain) const =0
Compression from linear samples+fine grain in the HTR.
const CaloTPGTranscoder * coder_

Member Data Documentation

◆ coder_

const CaloTPGTranscoder* HcalTPGCompressor::coder_
private

Definition at line 19 of file HcalTPGCompressor.h.

Referenced by compress().