CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
SiStripLorentzAngleReader.cc
Go to the documentation of this file.
3 
5 
6 #include <iostream>
7 #include <stdio.h>
8 #include <sys/time.h>
9 
10 
11 using namespace cms;
12 
14  printdebug_(iConfig.getUntrackedParameter<uint32_t>("printDebug",5)),
15  label_(iConfig.getUntrackedParameter<std::string>("label","")){}
17 
19 
20  edm::ESHandle<SiStripLorentzAngle> SiStripLorentzAngle_;
21  iSetup.get<SiStripLorentzAngleRcd>().get(label_,SiStripLorentzAngle_);
22  edm::LogInfo("SiStripLorentzAngleReader") << "[SiStripLorentzAngleReader::analyze] End Reading SiStripLorentzAngle with label " << label_<< std::endl;
23 
24  std::map<unsigned int,float> detid_la= SiStripLorentzAngle_->getLorentzAngles();
25  std::map<unsigned int,float>::const_iterator it;
26  size_t count=0;
27  for (it=detid_la.begin();it!=detid_la.end() && count<printdebug_;it++)
28  {
29  edm::LogInfo("SiStripLorentzAngleReader") << "detid " << it->first << " \t"
30  << " Lorentz angle " << it->second;
31  count++;
32  }
33 }
34 
const T & get() const
Definition: EventSetup.h:55
void analyze(const edm::Event &, const edm::EventSetup &)
SiStripLorentzAngleReader(const edm::ParameterSet &)