13 #include "xercesc/util/PlatformUtils.hpp" 35 baseRcd.
get( baseSettings ) ;
37 if (objectKey.empty()) {
38 edm::LogError(
"L1-O2O: L1TMuonBarrelParamsOnlineProd" ) <<
"Key is empty, returning empty L1TMuonBarrelParams";
40 throw std::runtime_error(
"SummaryForFunctionManager: BMTF | Faulty | Empty objectKey");
42 edm::LogError(
"L1-O2O: L1TMuonBarrelParamsOnlineProd" ) <<
"returning unmodified prototype of L1TMuonBarrelParams";
43 return std::make_shared< L1TMuonBarrelParams >( *(baseSettings.product()) ) ;
47 std::string tscKey = objectKey.substr(0, objectKey.find(
":") );
48 std::string rsKey = objectKey.substr( objectKey.find(
":")+1, std::string::npos );
51 edm::LogInfo(
"L1-O2O: L1TMuonBarrelParamsOnlineProd" ) <<
"Producing L1TMuonBarrelParams with TSC key = " << tscKey <<
" and RS key = " << rsKey ;
55 std::string hw_payload, algo_payload, mp7_payload, amc13_payload;
57 std::map<std::string,std::string>
keys =
63 algo_key = keys[
"ALGO"];
80 std::map<std::string,std::string> rsKeys =
86 mp7_key = rsKeys[
"MP7"];
87 amc13_key = rsKeys[
"AMC13"];
102 }
catch ( std::runtime_error &
e ) {
103 edm::LogError(
"L1-O2O: L1TMuonBarrelParamsOnlineProd" ) << e.what();
105 throw std::runtime_error(
std::string(
"SummaryForFunctionManager: BMTF | Faulty | ") + e.what());
107 edm::LogError(
"L1-O2O: L1TMuonBarrelParamsOnlineProd" ) <<
"returning unmodified prototype of L1TMuonBarrelParams";
108 return std::make_shared< L1TMuonBarrelParams >( *(baseSettings.product()) ) ;
155 }
catch ( std::runtime_error &e ) {
156 edm::LogError(
"L1-O2O: L1TMuonBarrelParamsOnlineProd" ) << e.what();
158 throw std::runtime_error(
std::string(
"SummaryForFunctionManager: BMTF | Faulty | ") + e.what());
160 edm::LogError(
"L1-O2O: L1TMuonBarrelParamsOnlineProd" ) <<
"returning unmodified prototype of L1TMuonBarrelParams";
161 return std::make_shared< L1TMuonBarrelParams >( *(baseSettings.product()) ) ;
168 }
catch ( std::runtime_error &e ) {
169 edm::LogError(
"L1-O2O: L1TMuonBarrelParamsOnlineProd" ) << e.what();
171 throw std::runtime_error(
std::string(
"SummaryForFunctionManager: BMTF | Faulty | ") + e.what());
173 edm::LogError(
"L1-O2O: L1TMuonBarrelParamsOnlineProd" ) <<
"returning unmodified prototype of L1TMuonBarrelParams";
174 return std::make_shared< L1TMuonBarrelParams >( *(baseSettings.product()) ) ;
178 std::shared_ptr< L1TMuonBarrelParams > retval = std::make_shared< L1TMuonBarrelParams>( m_params_helper );
180 edm::LogInfo(
"L1-O2O: L1TCaloParamsOnlineProd" ) <<
"SummaryForFunctionManager: BMTF | OK | All looks good";
T getParameter(std::string const &) const
void setConfigured(bool state=true) noexcept
~L1TMuonBarrelParamsOnlineProd(void) override
l1t::OMDSReader m_omdsReader
void readDOMFromString(const std::string &str, xercesc::DOMDocument *&doc)
static std::map< std::string, std::string > fetch(const std::vector< std::string > &queryColumns, const std::string &table, const std::string &key, l1t::OMDSReader &m_omdsReader)
void get(HolderT &iHolder) const
std::shared_ptr< L1TMuonBarrelParams > newObject(const std::string &objectKey, const L1TMuonBarrelParamsO2ORcd &record) override
#define DEFINE_FWK_EVENTSETUP_MODULE(type)
void readRootElement(TriggerSystem &aTriggerSystem, const std::string &sysId="")
void configFromDB(l1t::TriggerSystem &trgSys)
L1TMuonBarrelParamsOnlineProd(const edm::ParameterSet &)