CMS 3D CMS Logo

Public Member Functions | Private Attributes

ClusterSummarySingleMultiplicity Class Reference

#include <Multiplicities.h>

List of all members.

Public Member Functions

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

Private Attributes

std::vector< std::string > m_clustsummvar
edm::InputTag m_collection
int m_mult
int m_subdetenum
std::string m_subdetvar

Detailed Description

Definition at line 24 of file Multiplicities.h.


Constructor & Destructor Documentation

ClusterSummarySingleMultiplicity::ClusterSummarySingleMultiplicity ( )

Definition at line 4 of file Multiplicities.cc.

ClusterSummarySingleMultiplicity::ClusterSummarySingleMultiplicity ( const edm::ParameterSet iConfig)

Definition at line 7 of file Multiplicities.cc.

References m_clustsummvar.

                                                                                                :
  m_collection(iConfig.getParameter<edm::InputTag>("clusterSummaryCollection")),
  m_subdetenum(iConfig.getParameter<int>("subDetEnum")),
  m_subdetvar(iConfig.getParameter<std::string>("subDetVariable")),
  m_clustsummvar(),
  m_mult(0)
{ 

  m_clustsummvar.push_back("cHits");
  m_clustsummvar.push_back("cSize");
  m_clustsummvar.push_back("cCharge");
  m_clustsummvar.push_back("pHits");
  m_clustsummvar.push_back("pSize");
  m_clustsummvar.push_back("pCharge");

}

Member Function Documentation

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

Definition at line 24 of file Multiplicities.cc.

References edm::Event::getByLabel(), m_clustsummvar, m_collection, m_mult, m_subdetenum, and m_subdetvar.

                                                                                                   {

  m_mult = 0;

  edm::Handle<ClusterSummary> clustsumm;
  iEvent.getByLabel(m_collection,clustsumm);

  clustsumm->SetUserContent(m_clustsummvar);

  m_mult = int(clustsumm->GetGenericVariable(m_subdetvar,m_subdetenum));

}
int ClusterSummarySingleMultiplicity::mult ( ) const

Definition at line 37 of file Multiplicities.cc.

References m_mult.

{ return m_mult; }

Member Data Documentation

std::vector<std::string> ClusterSummarySingleMultiplicity::m_clustsummvar [private]

Definition at line 37 of file Multiplicities.h.

Referenced by ClusterSummarySingleMultiplicity(), and getEvent().

Definition at line 34 of file Multiplicities.h.

Referenced by getEvent().

Definition at line 38 of file Multiplicities.h.

Referenced by getEvent(), and mult().

Definition at line 35 of file Multiplicities.h.

Referenced by getEvent().

Definition at line 36 of file Multiplicities.h.

Referenced by getEvent().