CMS 3D CMS Logo

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

#include <HcalInterpolatedPulseColl.h>

Public Member Functions

const HcalInterpolatedPulsegetChannelPulse (const HcalDetId &id) const
 
const HcalInterpolatedPulsegetChannelPulse (const unsigned i) const
 
 HcalInterpolatedPulseColl (const std::vector< HcalInterpolatedPulse > &pulses, const HBHEChannelGroups &groups)
 
 HcalInterpolatedPulseColl ()
 
bool operator!= (const HcalInterpolatedPulseColl &r)
 
bool operator== (const HcalInterpolatedPulseColl &r)
 

Private Member Functions

template<class Archive >
void serialize (Archive &ar, unsigned)
 

Private Attributes

HBHEChannelGroups groups_
 
std::vector< HcalInterpolatedPulsepulses_
 

Friends

class boost::serialization::access
 

Detailed Description

Definition at line 8 of file HcalInterpolatedPulseColl.h.

Constructor & Destructor Documentation

HcalInterpolatedPulseColl::HcalInterpolatedPulseColl ( const std::vector< HcalInterpolatedPulse > &  pulses,
const HBHEChannelGroups groups 
)

Definition at line 4 of file HcalInterpolatedPulseColl.cc.

References Exception, groups_, HBHEChannelGroups::largestGroupNumber(), pulses_, and mitigatedMETSequence_cff::U.

6  : pulses_(pulses), groups_(groups) {
7  if (!(pulses_.size() == groups_.largestGroupNumber() + 1U))
8  throw cms::Exception("Inconsistent arguments in HcalInterpolatedPulseColl constructor");
9 }
std::vector< HcalInterpolatedPulse > pulses_
unsigned largestGroupNumber() const
HcalInterpolatedPulseColl::HcalInterpolatedPulseColl ( )
inline

Definition at line 29 of file HcalInterpolatedPulseColl.h.

29 {}

Member Function Documentation

const HcalInterpolatedPulse & HcalInterpolatedPulseColl::getChannelPulse ( const HcalDetId id) const

Definition at line 11 of file HcalInterpolatedPulseColl.cc.

References LEDCalibrationChannels::depth, HBHEChannelGroups::getGroup(), groups_, hbheChannelMap(), LEDCalibrationChannels::ieta, LEDCalibrationChannels::iphi, HBHELinearMap::linearIndex(), and pulses_.

11  {
12  // Figure out the group number for this channel
13  const unsigned lindex = hbheChannelMap().linearIndex(id.depth(), id.ieta(), id.iphi());
14  const unsigned grN = groups_.getGroup(lindex);
15 
16  // Return the pulse for this group
17  return pulses_[grN];
18 }
unsigned getGroup(const unsigned linearChannel) const
std::vector< HcalInterpolatedPulse > pulses_
const HBHELinearMap & hbheChannelMap()
unsigned linearIndex(unsigned depth, int ieta, unsigned iphi) const
const HcalInterpolatedPulse& HcalInterpolatedPulseColl::getChannelPulse ( const unsigned  i) const
inline

Definition at line 16 of file HcalInterpolatedPulseColl.h.

References HBHEChannelGroups::getGroup(), groups_, and pulses_.

16 { return pulses_[groups_.getGroup(i)]; }
unsigned getGroup(const unsigned linearChannel) const
std::vector< HcalInterpolatedPulse > pulses_
bool HcalInterpolatedPulseColl::operator!= ( const HcalInterpolatedPulseColl r)
inline

Definition at line 20 of file HcalInterpolatedPulseColl.h.

References alignCSCRings::r.

20 { return !(*this == r); }
bool HcalInterpolatedPulseColl::operator== ( const HcalInterpolatedPulseColl r)
inline

Definition at line 18 of file HcalInterpolatedPulseColl.h.

References groups_, and pulses_.

18 { return pulses_ == r.pulses_ && groups_ == r.groups_; }
std::vector< HcalInterpolatedPulse > pulses_
template<class Archive >
void HcalInterpolatedPulseColl::serialize ( Archive &  ar,
unsigned   
)
inlineprivate

Definition at line 35 of file HcalInterpolatedPulseColl.h.

References groups_.

35  {
36  ar& pulses_& groups_;
37  }
std::vector< HcalInterpolatedPulse > pulses_

Friends And Related Function Documentation

friend class boost::serialization::access
friend

Definition at line 32 of file HcalInterpolatedPulseColl.h.

Member Data Documentation

HBHEChannelGroups HcalInterpolatedPulseColl::groups_
private
std::vector<HcalInterpolatedPulse> HcalInterpolatedPulseColl::pulses_
private