File indexing completed on 2024-04-06 12:03:14
0001 #include "CondTools/L1TriggerExt/plugins/L1TriggerKeyDummyProdExt.h"
0002
0003 L1TriggerKeyDummyProdExt::L1TriggerKeyDummyProdExt(const edm::ParameterSet& iConfig) {
0004
0005
0006
0007
0008
0009 std::string label = iConfig.getParameter<std::string>("label");
0010 setWhatProduced(this, label);
0011
0012
0013 m_key.setTSCKey(iConfig.getParameter<std::string>("tscKey"));
0014 m_key.setSubsystemKey(L1TriggerKeyExt::kuGT, iConfig.getParameter<std::string>("uGTKey"));
0015 m_key.setSubsystemKey(L1TriggerKeyExt::kuGMT, iConfig.getParameter<std::string>("uGMTKey"));
0016 m_key.setSubsystemKey(L1TriggerKeyExt::kBMTF, iConfig.getParameter<std::string>("BMTFKey"));
0017 m_key.setSubsystemKey(L1TriggerKeyExt::kCALO, iConfig.getParameter<std::string>("CALOKey"));
0018
0019 if (label != "SubsystemKeysOnly") {
0020 typedef std::vector<edm::ParameterSet> ObjectKeys;
0021 ObjectKeys keys = iConfig.getParameter<ObjectKeys>("objectKeys");
0022
0023 for (ObjectKeys::const_iterator it = keys.begin(); it != keys.end(); ++it) {
0024
0025 std::string key = it->getParameter<std::string>("key");
0026 replace(key.begin(), key.end(), '?', ' ');
0027
0028 m_key.add(it->getParameter<std::string>("record"), it->getParameter<std::string>("type"), key);
0029 }
0030 }
0031 }
0032
0033 L1TriggerKeyDummyProdExt::~L1TriggerKeyDummyProdExt() {
0034
0035
0036 }
0037
0038
0039
0040
0041
0042
0043 L1TriggerKeyDummyProdExt::ReturnType L1TriggerKeyDummyProdExt::produce(const L1TriggerKeyExtRcd& iRecord) {
0044 return std::make_unique<L1TriggerKeyExt>(m_key);
0045 }
0046
0047
0048