CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
List of all members | Public Member Functions | Private Attributes
ClusterSummarySingleMultiplicity Class Reference

#include <Multiplicities.h>

Public Member Functions

 ClusterSummarySingleMultiplicity ()
 
 ClusterSummarySingleMultiplicity (const edm::ParameterSet &iConfig, edm::ConsumesCollector &&iC)
 
 ClusterSummarySingleMultiplicity (const edm::ParameterSet &iConfig, edm::ConsumesCollector &iC)
 
void getEvent (const edm::Event &iEvent, const edm::EventSetup &iSetup)
 
int mult () const
 

Private Attributes

edm::EDGetTokenT< ClusterSummarym_collection
 
int m_mult
 
ClusterSummary::CMSTracker m_subdetenum
 
ClusterSummary::VariablePlacement m_varenum
 

Detailed Description

Definition at line 30 of file Multiplicities.h.

Constructor & Destructor Documentation

ClusterSummarySingleMultiplicity::ClusterSummarySingleMultiplicity ( )
ClusterSummarySingleMultiplicity::ClusterSummarySingleMultiplicity ( const edm::ParameterSet iConfig,
edm::ConsumesCollector &&  iC 
)

Definition at line 6 of file Multiplicities.cc.

8  : m_subdetenum((ClusterSummary::CMSTracker)iConfig.getParameter<int>("subDetEnum")),
10  m_mult(0),
11  m_collection(iC.consumes<ClusterSummary>(iConfig.getParameter<edm::InputTag>("clusterSummaryCollection"))) {}
EDGetTokenT< ProductType > consumes(edm::InputTag const &tag)
ClusterSummary::VariablePlacement m_varenum
T getParameter(std::string const &) const
Definition: ParameterSet.h:303
ClusterSummary::CMSTracker m_subdetenum
edm::EDGetTokenT< ClusterSummary > m_collection
ClusterSummarySingleMultiplicity::ClusterSummarySingleMultiplicity ( const edm::ParameterSet iConfig,
edm::ConsumesCollector iC 
)

Definition at line 13 of file Multiplicities.cc.

15  : m_subdetenum((ClusterSummary::CMSTracker)iConfig.getParameter<int>("subDetEnum")),
17  m_mult(0),
18  m_collection(iC.consumes<ClusterSummary>(iConfig.getParameter<edm::InputTag>("clusterSummaryCollection"))) {}
EDGetTokenT< ProductType > consumes(edm::InputTag const &tag)
ClusterSummary::VariablePlacement m_varenum
T getParameter(std::string const &) const
Definition: ParameterSet.h:303
ClusterSummary::CMSTracker m_subdetenum
edm::EDGetTokenT< ClusterSummary > m_collection

Member Function Documentation

void ClusterSummarySingleMultiplicity::getEvent ( const edm::Event iEvent,
const edm::EventSetup iSetup 
)

Definition at line 20 of file Multiplicities.cc.

References ClusterSummary::CLUSTERCHARGE, ClusterSummary::CLUSTERSIZE, edm::Event::getByToken(), m_collection, m_mult, m_subdetenum, m_varenum, and ClusterSummary::NCLUSTERS.

20  {
21  m_mult = 0;
22 
24  iEvent.getByToken(m_collection, clustsumm);
25 
26  switch (m_varenum) {
28  m_mult = int(clustsumm->getNClus(m_subdetenum));
29  break;
31  m_mult = int(clustsumm->getClusSize(m_subdetenum));
32  break;
34  m_mult = int(clustsumm->getClusCharge(m_subdetenum));
35  break;
36  default:
37  m_mult = -1;
38  }
39 }
bool getByToken(EDGetToken token, Handle< PROD > &result) const
Definition: Event.h:539
ClusterSummary::VariablePlacement m_varenum
ClusterSummary::CMSTracker m_subdetenum
edm::EDGetTokenT< ClusterSummary > m_collection
int ClusterSummarySingleMultiplicity::mult ( ) const

Definition at line 41 of file Multiplicities.cc.

References m_mult.

Member Data Documentation

edm::EDGetTokenT<ClusterSummary> ClusterSummarySingleMultiplicity::m_collection
private

Definition at line 43 of file Multiplicities.h.

Referenced by getEvent().

int ClusterSummarySingleMultiplicity::m_mult
private

Definition at line 42 of file Multiplicities.h.

Referenced by getEvent(), and mult().

ClusterSummary::CMSTracker ClusterSummarySingleMultiplicity::m_subdetenum
private

Definition at line 40 of file Multiplicities.h.

Referenced by getEvent().

ClusterSummary::VariablePlacement ClusterSummarySingleMultiplicity::m_varenum
private

Definition at line 41 of file Multiplicities.h.

Referenced by getEvent().