#include <RPCAMCLinkMapHandler.h>
Definition at line 17 of file RPCAMCLinkMapHandler.h.
◆ RPCAMCLinkMapHandler()
Definition at line 14 of file RPCAMCLinkMapHandler.cc.
References Exception, n_sectors_, hgcalTBTopologyTester_cfi::sector, wos_fed_, and wos_sector_amc_.
20 wos_fed_(
config.getParameter<std::vector<int> >(
"wheelOrSideFED")),
24 std::vector<long long> wos_sector_amc_packed(
config.getParameter<std::vector<long long> >(
"wheelOrSideSectorAMC"));
26 if (
wos_fed_.size() != wos_sector_amc_packed.size()) {
27 throw cms::Exception(
"RPCAMCLinkMapHandler") <<
"Refuse to handle inconsistent input: " 28 <<
"sizes of wheelOrSideFED and wheelOrSideSectorAMC don't match";
31 std::vector<std::vector<int> >::iterator sector_amc =
wos_sector_amc_.begin();
32 for (std::vector<long long>::const_iterator sector_amc_packed = wos_sector_amc_packed.begin();
33 sector_amc_packed != wos_sector_amc_packed.end();
34 ++sector_amc_packed, ++sector_amc) {
std::string fullPath() const
std::vector< std::vector< int > > wos_sector_amc_
std::vector< int > wos_fed_
◆ ~RPCAMCLinkMapHandler()
RPCAMCLinkMapHandler::~RPCAMCLinkMapHandler |
( |
| ) |
|
|
override |
◆ getNewObjects()
void RPCAMCLinkMapHandler::getNewObjects |
( |
| ) |
|
|
overridevirtual |
Implements popcon::PopConSourceHandler< RPCAMCLinkMap >.
Definition at line 43 of file RPCAMCLinkMapHandler.cc.
References conv, Exception, input_file_, cond::TagInfo_t::lastInterval, mps_splice::line, MainPageGenerator::link, popcon::PopConSourceHandler< RPCAMCLinkMap >::m_to_transfer, n_sectors_, GetRecoTauVFromDQM_MC_cff::next, RPCLBLinkNameParser::parse(), hgcalTBTopologyTester_cfi::sector, cond::Iov_t::since, since_run_, AlCaHLTBitMon_QueryRunRegistry::string, popcon::PopConSourceHandler< RPCAMCLinkMap >::tagInfo(), txt_file_, makeMuonMisalignmentScenario::wheel, wheel_not_side_, wos_fed_, and wos_sector_amc_.
52 unsigned int wos,
sector, amc_number, amc_input;
54 std::unique_ptr<RPCAMCLinkMap> amc_link_map_object(
new RPCAMCLinkMap());
59 std::istringstream
conv;
63 input_file >> amc_name >> amc_input >> link_name;
64 std::getline(input_file,
line);
71 next = amc_name.find_first_not_of(
"+-0123456789",
pos);
78 next = amc_name.find_first_not_of(
"+-0123456789",
pos);
79 if (
next == std::string::npos)
80 next = amc_name.size();
85 wos = (amc_name.at(4) ==
'n' ? 0 : 1);
87 conv.str(amc_name.substr(5, 1));
93 <<
"Found sector greater than the number of sectors: " <<
sector <<
" > " <<
n_sectors_;
105 amc_link_map.insert(std::pair<RPCAMCLink, RPCLBLink>(
RPCAMCLink(
wos_fed_.at(wos), amc_number, amc_input), lb_link));
107 input_file >> amc_name >> amc_input >> link_name;
108 std::getline(input_file,
line);
115 for (
auto const link : amc_link_map) {
116 ofstream <<
link.first <<
": " <<
link.second << std::endl;
120 edm::LogInfo(
"RPCAMCLinkMapHandler") <<
"Add to transfer list";
cond::TagInfo_t const & tagInfo() const
std::vector< std::pair< RPCAMCLinkMap *, Time_t > > m_to_transfer
std::map< RPCAMCLink, RPCLBLink > map_type
Log< level::Info, false > LogInfo
std::vector< std::vector< int > > wos_sector_amc_
static void parse(std::string const &name, RPCLBLink &lb_link)
std::vector< int > wos_fed_
◆ id()
std::string RPCAMCLinkMapHandler::id |
( |
| ) |
const |
|
overridevirtual |
◆ data_tag_
std::string RPCAMCLinkMapHandler::data_tag_ |
|
protected |
◆ id_
std::string RPCAMCLinkMapHandler::id_ |
|
protected |
◆ input_file_
std::string RPCAMCLinkMapHandler::input_file_ |
|
protected |
◆ n_sectors_
unsigned int RPCAMCLinkMapHandler::n_sectors_ |
|
protected |
◆ since_run_
◆ txt_file_
std::string RPCAMCLinkMapHandler::txt_file_ |
|
protected |
◆ wheel_not_side_
bool RPCAMCLinkMapHandler::wheel_not_side_ |
|
protected |
◆ wos_fed_
std::vector<int> RPCAMCLinkMapHandler::wos_fed_ |
|
protected |
◆ wos_sector_amc_
std::vector<std::vector<int> > RPCAMCLinkMapHandler::wos_sector_amc_ |
|
protected |