test
CMS 3D CMS Logo

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

#include <SiStripSummaryReader.h>

Inheritance diagram for SiStripSummaryReader:
edm::EDAnalyzer edm::EDConsumerBase

Public Member Functions

void analyze (const edm::Event &, const edm::EventSetup &)
 
 SiStripSummaryReader (const edm::ParameterSet &)
 
 ~SiStripSummaryReader ()
 
- Public Member Functions inherited from edm::EDAnalyzer
void callWhenNewProductsRegistered (std::function< void(BranchDescription const &)> const &func)
 
 EDAnalyzer ()
 
ModuleDescription const & moduleDescription () const
 
std::string workerType () const
 
virtual ~EDAnalyzer ()
 
- Public Member Functions inherited from edm::EDConsumerBase
std::vector< ConsumesInfoconsumesInfo () const
 
 EDConsumerBase ()
 
ProductHolderIndexAndSkipBit indexFrom (EDGetToken, BranchType, TypeID const &) const
 
void itemsMayGet (BranchType, std::vector< ProductHolderIndexAndSkipBit > &) const
 
void itemsToGet (BranchType, std::vector< ProductHolderIndexAndSkipBit > &) const
 
std::vector
< ProductHolderIndexAndSkipBit >
const & 
itemsToGetFromEvent () const
 
void labelsForToken (EDGetToken iToken, Labels &oLabels) const
 
void modulesDependentUpon (std::string const &iProcessName, std::string const &iModuleLabel, bool iPrint, std::vector< char const * > &oModuleLabels) const
 
void modulesWhoseProductsAreConsumed (std::vector< ModuleDescription const * > &modules, ProductRegistry const &preg, std::map< std::string, ModuleDescription const * > const &labelsToDesc, std::string const &processName) const
 
bool registeredToConsume (ProductHolderIndex, bool, BranchType) const
 
bool registeredToConsumeMany (TypeID const &, BranchType) const
 
void updateLookup (BranchType iBranchType, ProductHolderIndexHelper const &)
 
virtual ~EDConsumerBase ()
 

Private Attributes

uint32_t printdebug_
 

Additional Inherited Members

- Public Types inherited from edm::EDAnalyzer
typedef EDAnalyzer ModuleType
 
- Public Types inherited from edm::EDConsumerBase
typedef ProductLabels Labels
 
- Static Public Member Functions inherited from edm::EDAnalyzer
static const std::string & baseType ()
 
static void fillDescriptions (ConfigurationDescriptions &descriptions)
 
static void prevalidate (ConfigurationDescriptions &)
 
- Protected Member Functions inherited from edm::EDConsumerBase
template<typename ProductType , BranchType B = InEvent>
EDGetTokenT< ProductType > consumes (edm::InputTag const &tag)
 
EDGetToken consumes (const TypeToGet &id, edm::InputTag const &tag)
 
template<BranchType B>
EDGetToken consumes (TypeToGet const &id, edm::InputTag const &tag)
 
ConsumesCollector consumesCollector ()
 Use a ConsumesCollector to gather consumes information from helper functions. More...
 
template<typename ProductType , BranchType B = InEvent>
void consumesMany ()
 
void consumesMany (const TypeToGet &id)
 
template<BranchType B>
void consumesMany (const TypeToGet &id)
 
template<typename ProductType , BranchType B = InEvent>
EDGetTokenT< ProductType > mayConsume (edm::InputTag const &tag)
 
EDGetToken mayConsume (const TypeToGet &id, edm::InputTag const &tag)
 
template<BranchType B>
EDGetToken mayConsume (const TypeToGet &id, edm::InputTag const &tag)
 

Detailed Description

Definition at line 18 of file SiStripSummaryReader.h.

Constructor & Destructor Documentation

SiStripSummaryReader::SiStripSummaryReader ( const edm::ParameterSet iConfig)
explicit

Definition at line 12 of file SiStripSummaryReader.cc.

12  :
13  printdebug_(iConfig.getUntrackedParameter<uint32_t>("printDebug",1)){}
T getUntrackedParameter(std::string const &, T const &) const
SiStripSummaryReader::~SiStripSummaryReader ( )

Definition at line 15 of file SiStripSummaryReader.cc.

15 {}

Member Function Documentation

void SiStripSummaryReader::analyze ( const edm::Event e,
const edm::EventSetup iSetup 
)
virtual

Implements edm::EDAnalyzer.

Definition at line 17 of file SiStripSummaryReader.cc.

References EnergyCorrector::c, edm::EventSetup::get(), i, printdebug_, and contentValuesCheck::ss.

17  {
18 
19  edm::ESHandle<SiStripSummary> SiStripSummary_;
20  iSetup.get<SiStripSummaryRcd>().get(SiStripSummary_);
21  edm::LogInfo("SiStripSummaryReader") << "[SiStripSummaryReader::analyze] End Reading SiStripSummary" << std::endl;
22 
23  std::vector<uint32_t> detid=SiStripSummary_->getDetIds();
24 
25 
26  std::vector<std::string> userDB=SiStripSummary_->getUserDBContent();
27  std::stringstream ss;
28  for(size_t i=0;i<userDB.size();++i)
29  ss<< userDB[i] << " \n";
30 
31 
32  if (printdebug_)
33  for (size_t id=0;id<detid.size();id++)
34  {
35  ss<< "\n\tdetid " << detid[id];
36  SiStripSummary::Range range=SiStripSummary_->getRange(detid[id]);
37 
38  size_t c=0;
39  for(SiStripSummary::ContainerIterator it =range.first;it!=range.second;++it){
40  ss << "\n\t\t " << userDB[c++] << " " << *it;
41  }
42  }
43  edm::LogInfo("SiStripSummaryReader") << ss.str();
44 }
int i
Definition: DBlmapReader.cc:9
std::pair< ContainerIterator, ContainerIterator > Range
const T & get() const
Definition: EventSetup.h:56
std::vector< float >::const_iterator ContainerIterator

Member Data Documentation

uint32_t SiStripSummaryReader::printdebug_
private

Definition at line 27 of file SiStripSummaryReader.h.

Referenced by analyze().