CMS 3D CMS Logo

List of all members | Public Member Functions | Private Attributes
reco::PixelClusterCountsInEvent Class Reference

#include <PixelClusterCountsInEvent.h>

Public Member Functions

unsigned int const & bxID () const
 
std::vector< int > const & counts () const
 
std::vector< int > const & countsRoc () const
 
void increment (int mD, int count)
 
void incrementRoc (int rD, int count)
 
std::vector< int > const & modID () const
 
 PixelClusterCountsInEvent ()
 
std::vector< int > const & rocID () const
 
void setbxID (unsigned int inputbxID)
 

Private Attributes

unsigned int m_bxID
 
std::vector< int > m_counts
 
std::vector< int > m_countsRoc
 
std::vector< int > m_ModID
 
std::vector< int > m_RocID
 

Detailed Description

Reconstructed PixelClusterCountsInEvent object that will contain the moduleID, bxID, and counts per event.

Authors
: Sam Higginbotham (shigg.nosp@m.inb@.nosp@m.cern..nosp@m.ch), Chris Palmer (capal.nosp@m.mer@.nosp@m.cern..nosp@m.ch), Attila Radl (attil.nosp@m.a.ra.nosp@m.dl@ce.nosp@m.rn.c.nosp@m.h)

Definition at line 15 of file PixelClusterCountsInEvent.h.

Constructor & Destructor Documentation

◆ PixelClusterCountsInEvent()

reco::PixelClusterCountsInEvent::PixelClusterCountsInEvent ( )
inline

Definition at line 17 of file PixelClusterCountsInEvent.h.

Member Function Documentation

◆ bxID()

unsigned int const& reco::PixelClusterCountsInEvent::bxID ( ) const
inline

Definition at line 47 of file PixelClusterCountsInEvent.h.

References m_bxID.

Referenced by reco::PixelClusterCounts::add().

◆ counts()

std::vector<int> const& reco::PixelClusterCountsInEvent::counts ( ) const
inline

Definition at line 39 of file PixelClusterCountsInEvent.h.

References m_counts.

Referenced by reco::PixelClusterCounts::add().

39 { return (m_counts); }

◆ countsRoc()

std::vector<int> const& reco::PixelClusterCountsInEvent::countsRoc ( ) const
inline

Definition at line 41 of file PixelClusterCountsInEvent.h.

References m_countsRoc.

Referenced by reco::PixelClusterCounts::add().

41 { return (m_countsRoc); }

◆ increment()

void reco::PixelClusterCountsInEvent::increment ( int  mD,
int  count 
)
inline

Definition at line 19 of file PixelClusterCountsInEvent.h.

References submitPVResolutionJobs::count, HLT_2024v13_cff::distance, spr::find(), m_counts, and m_ModID.

19  {
20  size_t modIndex = std::distance(m_ModID.begin(), std::find(m_ModID.begin(), m_ModID.end(), mD));
21  if (modIndex == m_ModID.size()) {
22  m_ModID.push_back(mD);
23  m_counts.push_back(0);
24  }
25  m_counts[modIndex] += count;
26  }
void find(edm::Handle< EcalRecHitCollection > &hits, DetId thisDet, std::vector< EcalRecHitCollection::const_iterator > &hit, bool debug=false)
Definition: FindCaloHit.cc:19

◆ incrementRoc()

void reco::PixelClusterCountsInEvent::incrementRoc ( int  rD,
int  count 
)
inline

Definition at line 28 of file PixelClusterCountsInEvent.h.

References submitPVResolutionJobs::count, HLT_2024v13_cff::distance, spr::find(), m_countsRoc, and m_RocID.

28  {
29  size_t rocIndex = std::distance(m_RocID.begin(), std::find(m_RocID.begin(), m_RocID.end(), rD));
30  if (rocIndex == m_RocID.size()) {
31  m_RocID.push_back(rD);
32  m_countsRoc.push_back(0);
33  }
34  m_countsRoc[rocIndex] += count;
35  }
void find(edm::Handle< EcalRecHitCollection > &hits, DetId thisDet, std::vector< EcalRecHitCollection::const_iterator > &hit, bool debug=false)
Definition: FindCaloHit.cc:19

◆ modID()

std::vector<int> const& reco::PixelClusterCountsInEvent::modID ( ) const
inline

Definition at line 43 of file PixelClusterCountsInEvent.h.

References m_ModID.

Referenced by reco::PixelClusterCounts::add().

43 { return (m_ModID); }

◆ rocID()

std::vector<int> const& reco::PixelClusterCountsInEvent::rocID ( ) const
inline

Definition at line 45 of file PixelClusterCountsInEvent.h.

References m_RocID.

Referenced by reco::PixelClusterCounts::add().

45 { return (m_RocID); }

◆ setbxID()

void reco::PixelClusterCountsInEvent::setbxID ( unsigned int  inputbxID)
inline

Definition at line 37 of file PixelClusterCountsInEvent.h.

References m_bxID.

37 { m_bxID = inputbxID; }

Member Data Documentation

◆ m_bxID

unsigned int reco::PixelClusterCountsInEvent::m_bxID
private

Definition at line 54 of file PixelClusterCountsInEvent.h.

Referenced by bxID(), and setbxID().

◆ m_counts

std::vector<int> reco::PixelClusterCountsInEvent::m_counts
private

Definition at line 50 of file PixelClusterCountsInEvent.h.

Referenced by counts(), and increment().

◆ m_countsRoc

std::vector<int> reco::PixelClusterCountsInEvent::m_countsRoc
private

Definition at line 51 of file PixelClusterCountsInEvent.h.

Referenced by countsRoc(), and incrementRoc().

◆ m_ModID

std::vector<int> reco::PixelClusterCountsInEvent::m_ModID
private

Definition at line 52 of file PixelClusterCountsInEvent.h.

Referenced by increment(), and modID().

◆ m_RocID

std::vector<int> reco::PixelClusterCountsInEvent::m_RocID
private

Definition at line 53 of file PixelClusterCountsInEvent.h.

Referenced by incrementRoc(), and rocID().