CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
JetTagComputerESProducer.h
Go to the documentation of this file.
1 #ifndef RecoBTau_JetTagComputerESProducer_h
2 #define RecoBTau_JetTagComputerESProducer_h
3 
4 #include <string>
5 #include <boost/static_assert.hpp>
6 #include <boost/type_traits.hpp>
7 #include <boost/shared_ptr.hpp>
8 #include <boost/make_shared.hpp>
9 
14 
15 template <typename ConcreteJetTagComputer>
17 private:
18  // check that the template parameter inherits from JetTagComputer
20 
21 public:
23  setWhatProduced(this, m_pset.getParameter<std::string>("@module_label") );
24 
25  m_jetTagComputer = boost::make_shared<ConcreteJetTagComputer>(m_pset);
26  }
27 
29  }
30 
31  boost::shared_ptr<JetTagComputer> produce(const JetTagComputerRecord & record) {
32  m_jetTagComputer->initialize(record);
33  m_jetTagComputer->setupDone();
34  return m_jetTagComputer;
35  }
36 
37 private:
38  boost::shared_ptr<JetTagComputer> m_jetTagComputer;
40 };
41 
42 #endif // RecoBTau_JetTagComputerESProducer_h
T getParameter(std::string const &) const
JetCorrectorParameters::Record record
Definition: classes.h:7
void setWhatProduced(T *iThis, const es::Label &iLabel=es::Label())
Definition: ESProducer.h:115
boost::shared_ptr< JetTagComputer > produce(const JetTagComputerRecord &record)
BOOST_STATIC_ASSERT((boost::is_convertible< ConcreteJetTagComputer *, JetTagComputer * >::value))
JetTagComputerESProducer(const edm::ParameterSet &pset)
boost::shared_ptr< JetTagComputer > m_jetTagComputer