CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
L1GtPrescaleFactorsAlgoTrigTrivialProducer.cc
Go to the documentation of this file.
1 
15 // this class header
17 
18 // system include files
19 #include <memory>
20 #include "boost/shared_ptr.hpp"
21 
22 #include <vector>
23 
24 // user include files
25 // base class
27 
30 
32 
33 // forward declarations
34 
35 // constructor(s)
37  const edm::ParameterSet& parSet) {
38 
39  // tell the framework what data is being produced
40  setWhatProduced(this,
42 
43  // now do what ever other initialization is needed
44 
45  // prescale factors
46 
47  std::vector<edm::ParameterSet> prescaleFactorsSet =
48  parSet.getParameter<std::vector<edm::ParameterSet> >("PrescaleFactorsSet");
49 
50  for (std::vector<edm::ParameterSet>::const_iterator itPfSet =
51  prescaleFactorsSet.begin(); itPfSet != prescaleFactorsSet.end(); ++itPfSet) {
52 
53  // prescale factors
54  m_prescaleFactors.push_back(itPfSet->getParameter<std::vector<int> >("PrescaleFactors"));
55 
56  }
57 
58 }
59 
60 // destructor
62 
63  // empty
64 
65 }
66 
67 // member functions
68 
69 // method called to produce the data
71  const L1GtPrescaleFactorsAlgoTrigRcd& iRecord) {
72 
73  boost::shared_ptr<L1GtPrescaleFactors> pL1GtPrescaleFactors =
74  boost::shared_ptr<L1GtPrescaleFactors>(
76 
77  return pL1GtPrescaleFactors;
78 }
T getParameter(std::string const &) const
boost::shared_ptr< L1GtPrescaleFactors > producePrescaleFactors(const L1GtPrescaleFactorsAlgoTrigRcd &)
public methods
void setWhatProduced(T *iThis, const es::Label &iLabel=es::Label())
Definition: ESProducer.h:115
L1GtPrescaleFactorsAlgoTrigTrivialProducer(const edm::ParameterSet &)
constructor
std::vector< std::vector< int > > m_prescaleFactors
prescale factors