#include <CaloSamples.h>
Public Member Functions | |
CaloSamples () | |
CaloSamples (const DetId &id, int size) | |
DetId | id () const |
get the (generic) id | |
bool | isBlank () const |
CaloSamples & | operator*= (double value) |
scale all samples | |
CaloSamples & | operator+= (double value) |
add a value to all samples | |
double & | operator[] (int i) |
mutable operator to access samples | |
double | operator[] (int i) const |
const operator to access samples | |
int | presamples () const |
access presample information | |
CaloSamples & | scale (double value) |
multiply each item by this value | |
void | setBlank () |
void | setDetId (DetId detId) |
void | setPresamples (int pre) |
set presample information | |
void | setSize (unsigned int size) |
int | size () const |
get the size | |
Static Public Attributes | |
static const int | MAXSAMPLES = 10 |
Private Attributes | |
double | data_ [MAXSAMPLES] |
DetId | id_ |
int | presamples_ |
int | size_ |
Class which represents the charge/voltage measurements of an event/channel with the ADC decoding performed.
Definition at line 15 of file CaloSamples.h.
CaloSamples::CaloSamples | ( | ) |
Definition at line 4 of file CaloSamples.cc.
References setBlank().
: id_(), size_(0), presamples_(0) { setBlank() ; }
CaloSamples::CaloSamples | ( | const DetId & | id, |
int | size | ||
) | [explicit] |
Definition at line 6 of file CaloSamples.cc.
References setBlank().
: id_ ( id ) , size_ ( size ) , presamples_ ( 0 ) { setBlank() ; }
DetId CaloSamples::id | ( | void | ) | const [inline] |
get the (generic) id
Definition at line 21 of file CaloSamples.h.
References id_.
Referenced by CaloHitResponse::add(), HcalAmplifier::addPedestals(), HPDIonFeedbackSim::addThermalNoise(), HcalAmplifier::amplify(), EcalElectronicsSim::amplify(), CastorAmplifier::amplify(), EcalMixingModuleValidation::computeSDBunchDigi(), HcalElectronicsSim::convert(), CastorElectronicsSim::convert(), ESElectronicsSim::encode(), EcalCoder::encode(), ESElectronicsSimFast::fastEncode(), HcalCoderDb::fC2adc_(), CastorCoderDb::fC2adc_(), HcalBaseSignalGenerator::fC2pe(), operator<<(), HcalAmplifier::pe2fC(), CastorNominalCoderTemplate::process(), HcalNominalCoderTemplate::process(), edm::DataMixingHcalDigiWorker::putHcal(), and ESElectronicsSimFast::standEncode().
{ return id_; }
bool CaloSamples::isBlank | ( | ) | const |
Definition at line 35 of file CaloSamples.cc.
References data_, ExpressReco_HICollisions_FallBack::e, funct::false, i, MAXSAMPLES, and funct::true.
Referenced by CaloHitRespoNew::findSignal().
CaloSamples& CaloSamples::operator*= | ( | double | value | ) | [inline] |
CaloSamples & CaloSamples::operator+= | ( | double | value | ) |
add a value to all samples
Definition at line 28 of file CaloSamples.cc.
References data_, i, and MAXSAMPLES.
double CaloSamples::operator[] | ( | int | i | ) | const [inline] |
double& CaloSamples::operator[] | ( | int | i | ) | [inline] |
int CaloSamples::presamples | ( | ) | const [inline] |
access presample information
Definition at line 31 of file CaloSamples.h.
References presamples_.
Referenced by CaloHitResponse::add(), HcalCoderDb::fC2adc_(), CastorCoderDb::fC2adc_(), CastorNominalCoderTemplate::process(), and HcalNominalCoderTemplate::process().
{ return presamples_; }
CaloSamples & CaloSamples::scale | ( | double | value | ) |
multiply each item by this value
Definition at line 21 of file CaloSamples.cc.
References data_, i, and MAXSAMPLES.
Referenced by operator*=().
void CaloSamples::setBlank | ( | ) |
Definition at line 45 of file CaloSamples.cc.
References data_, and MAXSAMPLES.
Referenced by CaloSamples().
{ std::fill( data_ , data_ + MAXSAMPLES, (double)0.0 ) ; }
void CaloSamples::setDetId | ( | DetId | detId | ) | [inline] |
void CaloSamples::setPresamples | ( | int | pre | ) |
set presample information
Definition at line 15 of file CaloSamples.cc.
References presamples_.
Referenced by HcalNominalCoder::adc2fC(), CastorNominalCoder::adc2fC(), HcalCoderDb::adc2fC_(), and CastorCoderDb::adc2fC_().
{ presamples_ = pre ; }
void CaloSamples::setSize | ( | unsigned int | size | ) | [inline] |
int CaloSamples::size | ( | void | ) | const [inline] |
get the size
Definition at line 24 of file CaloSamples.h.
References size_.
Referenced by CaloHitResponse::add(), HcalAmplifier::addPedestals(), HPDIonFeedbackSim::addThermalNoise(), CastorAmplifier::amplify(), EcalCoder::analogToDigital(), ESElectronicsSim::analogToDigital(), ESElectronicsSimFast::analogToDigital(), HcalElectronicsSim::convert(), CastorElectronicsSim::convert(), ESElectronicsSim::encode(), EcalCoder::encode(), ESElectronicsSimFast::fastEncode(), HcalCoderDb::fC2adc_(), CastorCoderDb::fC2adc_(), reco::HcalNoiseInfoProducer::filldigis(), GlobalDigisAnalyzer::fillHCal(), GlobalDigisProducer::fillHCal(), CaloHitResponse::makeAnalogSignal(), HcalSiPMHitResponse::makeSiPMSignal(), operator<<(), CastorNominalCoderTemplate::process(), HcalNominalCoderTemplate::process(), CaloHitRespoNew::putAnalogSignal(), edm::DataMixingHcalDigiWorker::putHcal(), HcalDigiTester::reco(), HcalSimpleRecAlgoImpl::reco(), CastorSimpleRecAlgoImpl::reco(), ZdcSimpleRecAlgoImpl::reco1(), ZdcSimpleRecAlgoImpl::reco2(), HcalSimpleRecAlgo::reconstruct(), setSize(), and ESElectronicsSimFast::standEncode().
{ return size_; }
double CaloSamples::data_[MAXSAMPLES] [private] |
Definition at line 54 of file CaloSamples.h.
Referenced by isBlank(), operator+=(), operator[](), scale(), and setBlank().
DetId CaloSamples::id_ [private] |
Definition at line 53 of file CaloSamples.h.
Referenced by id(), and setDetId().
const int CaloSamples::MAXSAMPLES = 10 [static] |
Definition at line 51 of file CaloSamples.h.
Referenced by EcalMixingModuleValidation::computeSDBunchDigi(), isBlank(), operator+=(), scale(), and setBlank().
int CaloSamples::presamples_ [private] |
Definition at line 55 of file CaloSamples.h.
Referenced by presamples(), and setPresamples().
int CaloSamples::size_ [private] |
Definition at line 55 of file CaloSamples.h.