CMS 3D CMS Logo

L1TMuonOverlapParamsOnlineProd.cc
Go to the documentation of this file.
1 #include <iostream>
2 #include <fstream>
3 #include <stdexcept>
4 
9 
10 class L1TMuonOverlapParamsOnlineProd : public L1ConfigOnlineProdBaseExt<L1TMuonOverlapParamsO2ORcd,L1TMuonOverlapParams> {
11 private:
13 
14 public:
15  std::unique_ptr<const L1TMuonOverlapParams> newObject(const std::string& objectKey, const L1TMuonOverlapParamsO2ORcd& record) override ;
16 
19 };
20 
22  transactionSafe = iConfig.getParameter<bool>("transactionSafe");
23 }
24 
25 std::unique_ptr<const L1TMuonOverlapParams> L1TMuonOverlapParamsOnlineProd::newObject(const std::string& objectKey, const L1TMuonOverlapParamsO2ORcd& record) {
26 
27  edm::LogError( "L1-O2O" ) << "L1TMuonOverlapParams object with key " << objectKey << " not in ORCON!" ;
28 
29  if( transactionSafe )
30  throw std::runtime_error("SummaryForFunctionManager: OMTF | Faulty | You are never supposed to get OMTF online producer running!");
31 
32  auto retval = std::make_unique< const L1TMuonOverlapParams >();
33 
34  edm::LogError( "L1-O2O: L1TMuonOverlapParamsOnlineProd" ) << "SummaryForFunctionManager: OMTF | Faulty | You are never supposed to get OMTF online producer running; returning empty L1TMuonOverlapParams";
35  return retval;
36 }
37 
38 //define this as a plug-in
T getParameter(std::string const &) const
JetCorrectorParameters::Record record
Definition: classes.h:7
std::unique_ptr< const L1TMuonOverlapParams > newObject(const std::string &objectKey, const L1TMuonOverlapParamsO2ORcd &record) override
L1TMuonOverlapParamsOnlineProd(const edm::ParameterSet &)
#define DEFINE_FWK_EVENTSETUP_MODULE(type)
Definition: ModuleFactory.h:60