13 for (
auto & thr :
l1menu->thresholds() ) {
27 unsigned int start = 0;
30 unsigned int end =
start + abs( thr->cableStart() - thr->cableEnd() );
34 m_mapByName[thr->name()] = ctpThr;
39 const std::vector< TrigConf::PIT* >& pit_vector)
47 if( pit->thresholdName() != thr->name() )
49 if( pit->pitNumber() < pit_start )
50 pit_start = pit->pitNumber();
51 if( pit->pitNumber() > pit_end )
52 pit_end = pit->pitNumber();
56 m_mapByName[thr->name()] = ctpThr;
62 const std::vector< TrigConf::TIP* >& tip_vector)
70 if( tip->thresholdName() != thr->name() )
72 if( tip->tipNumber() < tip_start)
73 tip_start = tip->tipNumber();
74 if( tip->tipNumber() > tip_end )
75 tip_end = tip->tipNumber();
79 m_mapByName[thr->name()] = ctpThr;
84 for (
auto &
entry : m_mapByName ) {
89 std::vector<std::string>
91 std::vector<std::string> thrNames;
92 thrNames.reserve(m_mapByName.size());
93 for(
auto &
entry : m_mapByName ) {
94 thrNames.emplace_back(
entry.first);
102 return * m_mapByName.at( thrName );
105 throw std::runtime_error(
"Threshold " + thrName +
" not present in CTPSimulation's internal threshold map");